1 votes 1 votes Q-We are given set of n distinct elements and an unlabled binary tree with n nodes how many ways we can populate the tree with given set so that it becomes binary search tree ? Programming in C tree + – cjoshi asked Jun 26, 2017 cjoshi 550 views answer comment Share Follow See all 0 reply Please log in or register to add a comment.
0 votes 0 votes 1 way.. perform in order traversal of that unlabeled tree...as the nodes are traversed, assign them with elements in increasing order(since BST inorder is ascending)... joshi_nitish answered Jun 27, 2017 joshi_nitish comment Share Follow See all 0 reply Please log in or register to add a comment.