How many different binary trees and binary search trees can
be made from three nodes that contain the key values 1, 2 & 3?
Answer Posted / hazrat hussain
Formula For BST is
{(2n)!/(n!*n)}/(n+1)
So for
N=1 BST=1
N=2 BST=2
N=3 BST=5
N=4 BST=14
N=5 BST=42
and so on
| Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
Why would you use a linked list?
What is difference between list and set?
Which collection is fail safe?
Is arraylist a class?
Why is hashmap faster than arraylist?
What is a Queue? Explain its operation with example?
Run time memory allocation is known as in data structure?
What is the difference between hashset and arraylist?
Define the tree data structure.
How do you check if a stack is empty or not?
what is a balanced tree.
What is difference between an Array and ArrayList?
What is entryset in hashmap?
Different Types of pattern?
Can we use ordered set for performing binary search?