findOrder = function(numCourses, prerequisites) {
    const { graph, color, isDirectedAcyclicGraph, topologicalOrder } = buildGraph(numCourses, prerequisites);

    search(numCourses, graph, color, topologicalOrder, isDirectedAcyclicGraph)

    return isDirectedAcyclicGraph[0]
        ? topologicalOrder.reverse()
        : []
}
https://leetcode.com/problems/course-schedule-ii/
Time O(V + E) | Space O(V + E)
@param {number} numCourses
@param {number[][]} prerequisites
@return {number[]}