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
Describe the complexity of Binary search
What are different types of algorithms?
Is linked list faster than array?
What is a dequeue?
Can you make an arraylist of arrays?
What happens if we try to insert duplicate key in hashmap?
What is difference between concurrenthashmap and hashtable?
What is difference between list and set?
Define an algorithm. What are the properties of an algorithm?
What is the use of heap sort?
Tell me the difference between structure and array?
What is inserting in data structure?
Explain extended binary tree.
Define indegree of a graph?
What are the average and worst time complexity in a sorted binary tree is