Junção de Duas BSTs (caso particular): Difference between revisions

From Wiki**3

Root (talk | contribs)
No edit summary
 
Root (talk | contribs)
 
(No difference)

Latest revision as of 09:12, 12 November 2008

Esta função assume que todos os elementos da primeira BST têm chaves inferiores às dos elementos da segunda BST.

 link joinLR(link low, link high) {
   if (high == z) return low;
   high = partR(high, 0);
   high->l = low;
   return high;
 }