Intuit interview question

algorithm to find execution order dependencies.