Summary in Graph
Exam Summary (GO Classes CS Test Series 2025 | Data
Structures | Topic Wise Test 4)
Qs. Attempted: 0 Correct Marks: 0
0+0 0+0
Correct
Attempts:
0 Penalty Marks: 0
0+0 0+0
Incorrect
Attempts:
0 Resultant
Marks:
0
0+0 0+0
Total
Questions:
15
5 + 10
Total Marks: 25
5 + 20
Exam Duration: 45 Minutes
Time Taken: 0 Minutes
EXAM RESPONSE EXAM STATS FEEDBACK
Technical
Q #1 Numerical Type Award: 1 Penalty: 0 DS
Given a BST, there are some keys that, if inserted, will increase the height of the tree. For the BST below,
let N be a number of integer keys (distinct from those already in the tree) for which this is true. Each key
should increase the height if inserted alone, not with other keys.
Find N.
Your Answer: Correct Answer: 1 Not Attempted Time taken: 00min 00sec Discuss
Q #2 Multiple Choice Type Award: 1 Penalty: 0.33 DS
In an array-based implementation of a Heap, the right-child of the right-child of the node at index i, if it
exists, can be found at what array location? Index of the array starts from 1.
A. 4i + 3
B. 2i + 1
C. 4i + 1
D. 2i + 2
Your Answer: Correct Answer: A Not Attempted Time taken: 00min 00sec Discuss
Q #3 Multiple Choice Type Award: 1 Penalty: 0.33 DS
Suppose that T is a full binary tree. Consider two statements about T :
• S1 : If T has 100 internal nodes then the number of leaves in T is 101.
• S2 : If T has a total of 1001 nodes, then 500 of them must have children.
What is true about S1 and S2?
A. S1 is correct but S2 is incorrect
B. S1 is incorrect but S2 is correct
C. Both are correct
D. Both are incorrect
Your Answer: Correct Answer: C Not Attempted Time taken: 00min 00sec Discuss
Q #4 Multiple Select Type Award: 1 Penalty: 0 DS
Consider a min heap with 1023 distinct integers. If root is at 0th level then fill the blank given in below
sentence.
The 10th minimum of the heap might be at ______ level.
A. 1
B. 3
C. 8
D. 9
Your Answer: Correct Answer: A;B;C;D Not Attempted Time taken: 00min 00sec Discuss
Q #5 Numerical Type Award: 1 Penalty: 0 DS
A min-heap consists of 2047 elements, the minimum number of comparisons required to determine the
maximum number is _______.
Your Answer: Correct Answer: 1023 Not Attempted Time taken: 00min 00sec Discuss
Q #6 Numerical Type Award: 2 Penalty: 0 DS
Consider the binary tree where the number of nodes in each left sub-tree is within a factor of 2 of the
number of nodes in the corresponding right sub-tree. Also, a node is allowed to have only one child if that
child has no children. What will be the minimum number of nodes in such a tree with a height of 5? (root is
at a height of 1).
Your Answer: Correct Answer: 12 Not Attempted Time taken: 00min 00sec Discuss
Q #7 Numerical Type Award: 2 Penalty: 0 DS
The keys 2, 4, 6, 8, and 10 have been inserted, one by one, in some unknown order, into an initially empty
BST. The result is this BST:
How many permutations of the 2, 4, 6, 8, and 10 will generate this particular BST?
Your Answer: Correct Answer: 6 Not Attempted Time taken: 00min 00sec Discuss
Q #8 Multiple Select Type Award: 2 Penalty: 0 DS
Consider the following binary heap.
Suppose that the last operation performed in the binary heap above was inserting the key x. What is/are
possible values of x?
A. 19
B. 26
C. 32
D. 10
Your Answer: Correct Answer: A;B;C Not Attempted Time taken: 00min 00sec Discuss
Q #9 Multiple Choice Type Award: 2 Penalty: 0.67 DS
Suppose that a binary min-heap stores six elements with priorities 10, 20, 30, 40, 50, and 60 in its array
A. What is the largest of these items that could be stored in A[1]? (indexing starts from zero)
A. 20
B. 30
C. 40
D. 50
Your Answer: Correct Answer: C Not Attempted Time taken: 00min 00sec Discuss
Q #10 Multiple Choice Type Award: 2 Penalty: 0.67 DS
Consider a binary min heap with n distinct elements such that the third largest element is a right child of
the root.
What will be the MAXIMUM value of n?
A. 7
B. 8
C. 10
D. 11
Your Answer: Correct Answer: D Not Attempted Time taken: 00min 00sec Discuss
Q #11 Multiple Select Type Award: 2 Penalty: 0 DS
Which of the following is/are TRUE?
A. Insertion into an AVL tree always increases the number of leaves.
B. An AVL tree of height 3 has at least 7 nodes and at most 15 nodes
C. If inserting a node into an AVL tree requires rebalancing, then the height of the entire tree does not
change.
D. When removing a node from an AVL tree with n nodes, then at most 3 vertices need to be
rebalanced.
Your Answer: Correct Answer: B;C Not Attempted Time taken: 00min 00sec Discuss
Q #12 Numerical Type Award: 2 Penalty: 0 DS
Consider a binary tree in which the number of leaves (nodes with no children) in each left subtree is within
one of the number of leaves in the corresponding right subtree. More precisely, for each node in the tree, ∣
number-of-leaves(left subtree) − number-of-leaves(right subtree)∣≤ 1. What is the worst-case height of
such a tree of 20 nodes?
Your Answer: Correct Answer: 19 Not Attempted Time taken: 00min 02sec Discuss
Q #13 Numerical Type Award: 2 Penalty: 0 DS
How many ways there were to insert the values 1 − 7 into a binary search tree that would result in the
following tree:
Your Answer: Correct Answer: 80 Not Attempted Time taken: 00min 00sec Discuss
Q #14 Numerical Type Award: 2 Penalty: 0 DS
With 7 nodes of distinct values, how many Binary search trees (BST) can be formed such that exactly 1
leaf node is present?
Your Answer: Correct Answer: 64 Not Attempted Time taken: 00min 00sec Discuss
Q #15 Multiple Choice Type Award: 2 Penalty: 0.67 DS
When searching for the key value 30 in a binary search tree, nodes containing the key values
10, 20, 40, 50, 70, 80, 90 are traversed, not necessarily in the order given.
What will be the probability to encounter a probe sequence such that 20 appears as the 3rd element in the
probe?
A. 1/21
B. 2/21
C. 1/7
D. 2/7
Your Answer: Correct Answer: B Not Attempted Time taken: 00min 00sec Discuss
Copyright & Stuff