How will you remove a left horizontal link in an AA-tree?

Category: QuestionsHow will you remove a left horizontal link in an AA-tree?
Editor">Editor Staff asked 5 months ago

How will you remove a left horizontal link in an AA-tree?
 
(a) by performing right rotation
 
(b) by performing left rotation
 
(c) by deleting both the elements
 
(d) by inserting a new element
 
My doubt stems from Binary Trees in division Binary Trees of Data Structures & Algorithms I
 
I have been asked this question in final exam.

1 Answers
Editor">Editor Staff answered 5 months ago

Right option is (a) by performing right rotation
 
The explanation is: A left horizontal link is removed by right rotation.  A right horizontal link is removed by left rotation.


Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17

Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17

Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17

Notice: Trying to get property 'ID' of non-object in /home/fvckxqmi/public_html/wp-content/themes/blocksy/inc/single/single-helpers.php on line 17
Articles: 40701