Pergunta de entrevista da empresa Bridgewater Associates

How would you topologically sort a DAG?