随笔分类 - 数据结构 dfs序
摘要:B. Alyona and a tree 题目连接: http://codeforces.com/contest/739/problem/B Description Alyona has a tree with n vertices. The root of the tree is the vert
阅读全文
摘要:Snacks 题目连接: http://acm.hdu.edu.cn/showproblem.php?pid=5692 Description 百度科技园内有n个零食机,零食机之间通过n−1条路相互连通。每个零食机都有一个值v,表示为小度熊提供零食的价值。 由于零食被频繁的消耗和补充,零食机的价值v
阅读全文
摘要:Annoying problem 题目连接: http://acm.hdu.edu.cn/showproblem.php?pid=5293 Description Coco has a tree, whose vertices are conveniently labeled by 1,2,…,n.
阅读全文
摘要:Annoying problem 题目连接: http://acm.hdu.edu.cn/showproblem.php?pid=5296 Description Coco has a tree, whose nodes are conveniently labeled by 1,2,…,n, wh
阅读全文
摘要:G. Yash And Trees 题目连接: http://www.codeforces.com/contest/633/problem/G Description Yash loves playing with trees and gets especially excited when the
阅读全文
摘要:High-level ancientsTime Limit: 20 SecMemory Limit: 256 MB题目连接http://acm.uestc.edu.cn/#/problem/show/574DescriptionLove8909 is keen on the history of K...
阅读全文
摘要:#139. 【UER #4】被删除的黑白树Time Limit: 1 Sec Memory Limit: 256 MB题目连接http://uoj.ac/problem/139Description很久很久以前,有一棵树加入了 UOJ 群。这天,在它讨论“一棵树应该怎么旋转”的时候一不小心被删除了,...
阅读全文
摘要:D. Water TreeTime Limit: 1 Sec Memory Limit: 256 MB题目连接http://codeforces.com/contest/343/problem/DDescriptionMad scientist Mike has constructed a root...
阅读全文
摘要:C. Propagating treeTime Limit: 20 SecMemory Limit: 256 MB题目连接http://codeforces.com/contest/383/problem/CDescriptionIahub likes trees very much. Recent...
阅读全文