- 1、本文档共17页,可阅读全部内容。
- 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
- 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载。
- 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
- 5、该文档为VIP文档,如果想要下载,成为VIP会员后,下载免费。
- 6、成为VIP后,下载本文档将扣除1次下载权益。下载后,不支持退款、换文档。如有疑问请联系我们。
- 7、成为VIP后,您将拥有八大权益,权益包括:VIP文档下载权益、阅读免打扰、文档格式转换、高级专利检索、专属身份标志、高级客服、多端互通、版权登记。
- 8、VIP文档为合作方或网友上传,每下载1次, 网站将根据用户上传文档的质量评分、类型等,对文档贡献者给予高额补贴、流量扶持。如果你也想贡献VIP文档。上传文档
查看更多
关于红黑树(Red-Black Tree)英文简介
Red-Black Tree
Red-black Tree Type Tree Invented 1972 Invented by Rudolf Bayer Time complexityin big O notation Average Worst case Space O(n) O(n) Search O(log n) O(log n) Insert O(log n) O(log n) Delete O(log n) O(log n) A red-black tree is a type of self-balancing binary search tree, a data structure used in computing science, typically used to implement associative arrays. The original structure was invented in 1972 by Rudolf Bayer who called them symmetric binary B-trees, but acquired its modern name in a paper in 1978 by Leonidas J. Guibas and Robert Sedgewick. It is complex, but has good worst-case running time for its operations and is efficient in practice: it can search, insert, and delete in O(log n) time, where n is total number of elements in the tree. Put very simply, a red-black tree is a binary search tree which inserts and removes intelligently, to ensure the tree is reasonably balanced.
Terminology
A red-black tree is a special type of binary tree, used in computer science to organize pieces of comparable data, such as text fragments or numbers.
The leaf nodes of red-black trees do not contain data. These leaves need not be explicit in computer memory — a null child pointer can encode the fact that this child is a leaf — but it simplifies some algorithms for operating on red-black trees if the leaves really are explicit nodes. To save memory, sometimes a single sentinel node performs the role of all leaf nodes; all references from internal nodes to leaf nodes then point to the sentinel node.
Red-black trees, like all binary search trees, allow efficient in-order traversal in the fashion, Left-Root-Right, of their elements. The search-time results from the traversal from root to leaf, and therefore a balanced tree, having the least possible tree height, results in O(log n) search time.
Properties
An example of a red-black tree
A red-black tree is a binary search tree where each node has a color attribute, the value of which is either red
您可能关注的文档
- 必修五unit1 grammar 教案.doc
- 牛津5BModule1 Unit4 Use your five senses!.doc
- 研究生英语单词总结.docx
- 精读1-unit1.doc
- 2013年高三英语十月月考试卷.doc
- 必修5基础句型.doc
- 5BUnit7A busy day教案五课时(含后记).doc
- 新目标英语七年级下册(新)Unit 8基础过关练习.doc
- PEP小学英语五年级下《My Favourite Season》教学设计.doc
- unit 4 教师词汇.doc
- 自动驾驶汽车商业化推广政策对产业链协同影响分析报告.docx
- 数字货币对2025年货币政策传导的金融创新挑战与应对.docx
- 电商绿色物流物流园区绿色物流绿色物流园区绿色物流政策法规解读报告.docx
- 2025年物流配送中心建设与区域经济发展稳定风险评估报告.docx
- 2025年医疗行业人才流动机制与医疗人才培养质量研究报告.docx
- 2025年虚拟现实教育产品在体育课程中的应用效果评估报告.docx
- 2025年艺术市场数字化交易平台政策法规与标准体系建设报告.docx
- 城市轨道交通智慧运维系统2025年智能监控与数据分析技术研究报告.docx
- 2025年医疗行业人才流动机制改革与人才培养策略研究报告.docx
- 教育科技企业商业模式创新与教育科技企业创新能力评估报告.docx
文档评论(0)