Java
Content:
- Here we have class Node, Tree and Main:
- Tree class will be contain root of the binary tree
- Node class will be use to create and link the Node of tree
- Main class will be use to execute we project
How work's:
- First we need to insert the nodes in tree, by default the first will be the root, and next will be store using a rule, if the number of Node is minor than root, will be store in left Node, else if bigger than root it will be store on right Node
- The rule about inserting Nodes is used in sequence insertions, bigger on right Node and minor on left Node
- Next we have some methods to print the Tree data, see a degree of a Node or find a Node on Tree