Menu

Trees Questions

MCQ
101.
Why to prefer red-black trees over AVL trees?
forum Discussion
MCQ
102.
What is a Cartesian tree?
forum Discussion
MCQ
103.
Which of the below statements are true: i.Cartesian tree is not a height balanced tree ii.Cartesian tree of a sequence of unique numbers can be unique generated
forum Discussion
MCQ
104.
What is the speciality of cartesian sorting?
forum Discussion
MCQ
105.
Consider a sequence of numbers to have repetitions, how a cartesian tree can be constructed in such situations without violating any rules?
forum Discussion
MCQ
106.
After applying the below operations on a input sequence, what happens?

i. construct a cartesian tree for input sequence

ii. put the root element of above tree in a priority queue

iii. if( priority queue is not empty) then

.search and delete minimum value in priority queue

.add that to output

.add cartesian tree children of above node to priority queue
forum Discussion
MCQ
107.
Cartesian trees are most suitable for?
forum Discussion
MCQ
108.
A treap is a cartesian tree with
forum Discussion
MCQ
109.
Cartesian trees solve range minimum query problem in constant time
forum Discussion
MCQ
110.
Consider below sequences:

array=60 90 10 100 40 150 90

reverse 2 to 3

array=60 10 90 100 40 150 90

reverse 3 to 6

array= 60 100 150 40 100 90 90

now printout from 1 to 6 :-- 60 100 150 40 100 90

How to achieve the above operation efficiently?
forum Discussion