A degenerate binary tree is one where most or all of the nodes contain only one sub node. It is unbalanced and, in the worst case, performance degrades to that of a linked list. If your add node function does not handle rebalancing, then you can easily construct a degenerate tree by feeding it data that is already sorted.
Chat with our AI personalities
By using Depth First Search or Breadth First search Tree traversal algorithm we can print data in Binary search tree.
A binary search tree is already ordered. An in order traversal will give you a sorted list of nodes.
Yes because there is no real practical use for a binary tree other than something to teach in computer science classes. A binary tree is not used in the real world, a "B tree" is.
A strictly binary tree is one where every node other than the leaves has exactly 2 child nodes. Such trees are also known as 2-trees or full binary trees. An extended binary tree is a tree that has been transformed into a full binary tree. This transformation is achieved by inserting special "external" nodes such that every "internal" node has exactly two children.
A tree doesn't do anything so it has no speed...