Tree: Difference between revisions

From Wiki :-)
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
A Tree has (only one) root node and has child nodes. A leaf node has no child.
A Tree is a connected (there is a path between every vertices) and acyclic graph. If one edge is added to the tree, it will form a cycle and if one edge is removed from the tree, it will become disconnected.
 
A Tree has (only one) designated root node and has child nodes. A leaf node has no child.


In a binary tree, nodes have at most two children.
In a binary tree, nodes have at most two children.

Revision as of 04:55, 24 June 2018

A Tree is a connected (there is a path between every vertices) and acyclic graph. If one edge is added to the tree, it will form a cycle and if one edge is removed from the tree, it will become disconnected.

A Tree has (only one) designated root node and has child nodes. A leaf node has no child.

In a binary tree, nodes have at most two children.

Resources

https://www.youtube.com/watch?v=oSWTXtMglKE