当前位置:网站首页>Binary tree
Binary tree
2022-06-29 10:36:00 【Xihong Shiwang has many fish】
1. Definition
A binary tree is a tree structure in which each node has at most two subtrees . Usually a subtree is called “ The left subtree ”(left subtree) and “ Right subtree ”(right subtree).
Perfect binary tree : In a binary tree , Except for the last floor , If the rest of the layers are full , And the last layer is either full , Or there is a lack of consecutive nodes on the right .
2. Simple concept
The degree of node : The number of subtrees owned by the node .
leaf : A node of degree zero .
Branching nodes : Nodes with degree not zero .
The degree of a tree : The maximum degree of a node in a tree .
level : The level of the root node is 1, The hierarchy of the other nodes is equal to the hierarchy of the parent nodes of the node plus 1.
The height of the tree : The maximum level of nodes in a tree .
Disordered trees : If the order between the subtrees of the nodes in the tree is not important , You can switch places .
Ordered trees : If the order between the subtrees of nodes in a tree is important , You can't swap places .
The forest :0 One or more disjoint trees make up . Add a root to the forest , The forest becomes a tree ; Delete the root , Trees become forests .
边栏推荐
- Graphics learned from jigsaw puzzles h
- mysql 8.0 一条insert语句的具体执行流程分析(二)
- Arc view and arc viewpager
- CLR via C reading notes - loading and AppDomain
- 520 diamond Championship 2021
- Downloading and installing VMware (basic idea + detailed process)
- Picture verification code control
- 查看CSDN的博客排名
- 打印100~200之间的素数(C语言)
- Bug的描述、定级、生命周期
猜你喜欢
随机推荐
Ce projet Open source est super wow, des photos manuscrites sont générées en ligne
1147 heaps (30 points)
qgis制图
Real time value transfer from C form to another form
Analyze in detail the PBOT mining virus family behavior and the principle of exploited vulnerabilities, and provide detailed protection suggestions for the blue army
MySQL中的alter table操作之add/modify/drop列
2019.10.30 learning summary
SQL Server 数据库增删改查语句
Devaxpress double click to get cell data
Common usage of LINQ in C #
《CLR via C#》读书笔记-加载与AppDomain
Installing and configuring wmware esxi 6.5.0 in VMware Workstation
AQS之BlockingQueue源码解析
Wandering -- the last programming challenge
std::make_ shared<T>/std::make_ Unique < T> and std:: shared_ ptr<T>/std::unique_ The difference and relation between PTR < t >
IIS服务器相关错误
Add/modify/drop column of alter table operation in MySQL
C language library function --strstr()
Analysis on the specific execution process of an insert statement in MySQL 8.0 (3)
区域工业互联网市场成绩单,百度智能云开物第二









