树
文章平均质量分 95
Raytheon 1715313189
这个人是条懒狗,什么也没留下...
展开
-
1155 Heap Paths (30分)(月亮和星星在一起了/♥)
In computer science, a heap is a specialized tree-based data structure that satisfies the heap property: if P is a parent node of C, then the key (the value) of P is either greater than or equal to (...原创 2020-01-21 19:11:06 · 122 阅读 · 0 评论 -
1099 Build A Binary Search Tree (30分)(KO NO WA DIO DA!!!)
A Binary Search Tree (BST) is recursively defined as a binary tree which has the following properties:The left subtree of a node contains only nodes with keys less than the node's key. The right s...原创 2020-01-16 21:37:36 · 189 阅读 · 0 评论 -
1064 Complete Binary Search Tree (30point(s))(xxgm快点好啊!)
A Binary Search Tree (BST) is recursively defined as a binary tree which has the following properties:The left subtree of a node contains only nodes with keys less than the node's key. The right s...原创 2020-01-16 20:50:52 · 173 阅读 · 0 评论 -
1020 Tree Traversals (25分)(小雷明天开始要好好学习了!!!)
Suppose that all the keys in a binary tree are distinct positive integers. Given the postorder and inorder traversal sequences, you are supposed to output the level order traversal sequence of the co...原创 2020-01-11 23:09:25 · 104 阅读 · 0 评论 -
1090 Highest Price in Supply Chain(天上人间,潇潇共雨。曼珠红遍,流水忘川。)
A supply chain is a network of retailers(零售商), distributors(经销商), and suppliers(供应商)-- everyone involved in moving a product from supplier to customer.Starting from one root supplier, everyone on t...原创 2019-11-23 20:06:38 · 162 阅读 · 0 评论 -
1107 Social Clusters (30 分)(!!!!!引起不适!!!!谨慎阅读!!!!!!)
When register on a social network, you are always asked to specify your hobbies in order to find some potential friends with the same hobbies. Asocial clusteris a set of people who have some of the...原创 2019-11-14 21:29:29 · 945 阅读 · 0 评论 -
1106 Lowest Price in Supply Chain (25 分)(王德发?!!!!!)
A supply chain is a network of retailers(零售商), distributors(经销商), and suppliers(供应商)-- everyone involved in moving a product from supplier to customer.Starting from one root supplier, everyone on t...原创 2019-11-12 18:22:53 · 96 阅读 · 0 评论 -
1094 The Largest Generation (25 分)
A family hierarchy is usually presented by a pedigree tree where all the nodes on the same level belong to the same generation. Your task is to find the generation with the largest population.Input...原创 2019-11-12 16:37:08 · 170 阅读 · 0 评论 -
1004 Counting Leaves (30 分)(w u b l u b d u b d a)
A family hierarchy is usually presented by a pedigree tree. Your job is to count those family members who have no child.Input Specification:Each input file contains one test case. Each case start...原创 2019-11-10 12:37:00 · 96 阅读 · 0 评论 -
P1090 合并果子(哈夫曼树+STL)
题目描述在一个果园里,多多已经将所有的果子打了下来,而且按果子的不同种类分成了不同的堆。多多决定把所有的果子合成一堆。每一次合并,多多可以把两堆果子合并到一起,消耗的体力等于两堆果子的重量之和。可以看出,所有的果子经过n-1n−1次合并之后, 就只剩下一堆了。多多在合并果子时总共消耗的体力等于每次合并所耗体力之和。因为还要花大力气把这些果子搬回家,所以多多在合并果子时要尽可能地节...原创 2019-08-20 11:20:37 · 185 阅读 · 0 评论