My Report

Data Structure I Practice Test 5


Correct Answer: 2 points | Wrong: -1 point
Grades: A* (100% score) | A (80%-99%) | B (60%-80%) | C (40%-60%) | D (0%-40%)
advertisement

1. What is the longest length path for a node x in random binary search tree for the insertion process?

2. Cartesian trees are most suitable for?

3. Which process forms the randomized binary search tree?

4. Given that 2 elements are present in the tree, write a function to find the LCA(Least Common Ancestor) of the 2 elements.

5. For a binary tree the first node visited in in-order and post-order traversal is same.

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

7. Which of the following graph traversals closely imitates level order traversal of a binary tree?

8. Is the below tree representation of 50,100,400,300,280 correct way to represent cartesian tree?
data-structure-questions-answers-cartesian-tree-q2

9. Which of the following is a self - balancing binary search tree?

10. Consider a sequence of numbers to have repetitions, how a cartesian tree can be constructed in such situations without violating any rules?


 

Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.