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 / poornakala

for binary search tree, no of trees, (2^n)-n... here 8-3=5
trees... u can draw n see...

for binary tree, no of trees n(2^n)-n here 3*5=15...
replace node in each bst with other two values and see....

Is This Answer Correct ?    72 Yes 48 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is boolean a data type?

440


What is ds tree?

510


How memory is reserved using a declaration statement ?

652


What is a weighted graph?

547


Why do we Use a Multidimensional Array?

465






How do you declare A pointer to array of three chars

525


Can you make an arraylist of arrays?

557


Differentiate between iterator and listiterator.

621


Traverse the given tree using Inorder, Preorder and Postorder traversals. Inorder : D H B E A F C I G J Preorder: A B D H E C F G I J Postorder: H D E B F I J G C A

641


Which data structures are used in bfs and dfs algorithm?

549


Treemap orders the elements on which field?

507


Differentiate linear from a nonlinear data structure?

538


What is array sort?

494


What are different types of sorting algorithms?

474


What is the difference between arraylist and linkedlist?

476