Binary search tree

Правка en1, от tanvir_cse, 2016-08-15 18:41:11

i want to use a bst for each node of segment tree, then i want to union left bst and right bst into root,,,but when i implement it , it works for root successfully that means it root bst contain all element that left and right bst have and contain the property of bst but the problem is it change the data in left and right child that means for next time if i want to use the left or right bst (not root) it's not the previous bst that means it change with the union operation. im tried like that t->bst= unite(t->l->bst ,t->r->bst);

i want to merge the left and right bst in root and also want to the and right bst remain same....

plz anyone explin me how can i do it... thanx in advance

Теги bst, segment tree, advanced data structure

История

 
 
 
 
Правки
 
 
  Rev. Язык Кто Когда Δ Комментарий
en2 Английский tanvir_cse 2016-08-15 20:24:19 13
en1 Английский tanvir_cse 2016-08-15 18:41:11 719 Initial revision (published)