注册一亩三分地论坛,查看更多干货!
您需要 登录 才可以下载或查看附件。没有帐号?注册账号
x
You have a set of tasks. Tasks may depend on other tasks.
For example, if task A depends on task B, task B must be
completed before task A can be started.
If a task has multiple dependencies, all dependencies must
be completed before the task can be started.
You are given a task that needs to be completed.
Write a function that returns a list of tasks that must be
completed to complete the given task.
This list should
(1) satisfy the task request
(2) be in a valid order (i.e. all dependencies of a task come before it)
(3) not contain unnecessary or duplicate tasks.
Example:
0 => [ 1 2 ]
1 => [ 3 4 ]
2 => [ 4 ]
3 => [ ]
4 => [ ]
您好! 本帖隐藏的内容需要积分高于 188 才可浏览 您当前积分为 0。 使用VIP即刻解锁阅读权限或查看其他获取积分的方式 游客,您好! 本帖隐藏的内容需要积分高于 188 才可浏览 您当前积分为 0。 VIP即刻解锁阅读权限 或 查看其他获取积分的方式 sb 烙印manager,AM。
全程没读懂题,交流困难,不给input,输入输出要求自己写,问输出是什么解释不清。
遇见烙印赶紧润。
任务:
写函数 dps, 问每个任务 i不同,有不同的输出。
拓扑变种,课程表。
问C,c++, python编译原理,怎么做到的,很底层,答到汇编还不够。os怎么实现,工作的原理 , chrome的运行原理,电脑的运行过程。 |