Define Tree Data Structure

Technology CommunityCategory: TreesDefine Tree Data Structure
VietMX Staff asked 3 years ago

Trees are well-known as a non-linear data structure. They don’t store data in a linear way. They organize data hierarchically.

tree is a collection of entities called nodes. Nodes are connected by edges. Each node contains a value or data or key, and it may or may not have a child node. The first node of the tree is called the rootLeaves are the last nodes on a tree. They are nodes without children.