1494
1494. 并行课程 II (Hard)
问题描述 1494. 并行课程 II (Hard) 给你一个整数 n 表示某所大学里课程的数目,编号为 1 到 n ,数组 relations 中, relations[i] = [xᵢ, yᵢ] 表示一个先修课的关系,也就是课程 xᵢ 必须在课程 yᵢ 之前上。同时你还有一个整数 k 。 在一个学 ......
1494. Parallel Courses II (Hard)
Description 1494. Parallel Courses II (Hard) You are given an integer n, which indicates that there are n courses labeled from 1 to n. You are also gi ......
1494. 并行课程 II
给你一个整数 n 表示某所大学里课程的数目,编号为 1 到 n ,数组 relations 中, relations[i] = [xi, yi] 表示一个先修课的关系,也就是课程 xi 必须在课程 yi 之前上。同时你还有一个整数 k 。 在一个学期中,你 最多 可以同时上 k 门课,前提是这些课的 ......