
ACM-二叉树
文章平均质量分 85
蝉鸣的夏季
要在IT这条不归路上,越走越远了。
展开
-
hdu 1710 Binary Tree Traversals
Problem DescriptionA binary tree is a finite set of vertices that is either empty or consists of a root r and two disjoint binary trees called the left and right subtrees. There are three most impor转载 2016-12-27 21:33:27 · 218 阅读 · 0 评论 -
nyoj 202 红黑树
描述 什么是红黑树呢?顾名思义,跟枣树类似,红黑树是一种叶子是黑色果子是红色的树。。。当然,这个是我说的。。。《算法导论》上可不是这么说的:如果一个二叉查找树满足下面的红黑性质,那么则为一个红黑树。1)每个节点或是红的,或者是黑的。2)每个叶子节点(NIL)是黑色的3)如果一个节点是红色的,那么他的两个儿子都是黑的。4)根节点是黑色的。5)对于每个节点,从该节点原创 2017-05-03 09:36:41 · 231 阅读 · 0 评论