← 返回 uber 的题目列表Course Schedule
类型:online_judge
Given the total number of courses numCourses and a list of prerequisite pairs where [a, b] indicates that to take course a you must first complete course b, determine if it is possible to finish all the courses. Return true if possible, otherwise return false. It is guaranteed that there are no duplicate courses in the input. The number of courses is in the range of 1 to 10^5.
Example
Input
2
[[1, 0]]