摘要:
小C最近学了很多最小生成树的算法,Prim算法、Kurskal算法、消圈算法等等。正当小C洋洋得意之时,小P又来泼小C冷水了。小P说,让小C求出一个无向图的次小生成树,而且这个次小生成树还得是严格次小的,也就是说:如果最小生成树选择的边集是EM,严格次小生成树选择的边集是ES,那么需要满足:(val 阅读全文
摘要:
Discription Eighth-grader Vova is on duty today in the class. After classes, he went into the office to wash the board, and found on it the number n. 阅读全文
摘要:
Discription You have a team of N people. For a particular task, you can pick any non-empty subset of people. The cost of having x people for the task 阅读全文