摘要: D. Happy Tree Party Bogdan has a birthday today and mom gave him a tree consisting of n vertecies. For every edge of the tree i, some number xi was wr 阅读全文
posted @ 2016-08-13 16:01 meekyan 阅读(260) 评论(0) 推荐(0) 编辑
摘要: Problem 2082 过路费 Problem Description 有n座城市,由n-1条路相连通,使得任意两座城市之间可达。每条路有过路费,要交过路费才能通过。每条路的过路费经常会更新,现问你,当前情况下,从城市a到城市b最少要花多少过路费。 Input 有多组样例,每组样例第一行输入两个正 阅读全文
posted @ 2016-08-13 12:14 meekyan 阅读(257) 评论(0) 推荐(0) 编辑
摘要: C. Subsequences For the given sequence with n different elements find the number of increasing subsequences with k + 1 elements. It is guaranteed that 阅读全文
posted @ 2016-08-13 10:34 meekyan 阅读(229) 评论(0) 推荐(0) 编辑