GATE CS 2024 · Set-2 · Arrays & Matrix Representation

MCQ · 2 marks · Problem PROG-DSTR-0088

You are given a set \(V\) of distinct integers. A binary search tree \(T\) is created by inserting all elements of \(V\) one by one, starting with an empty tree. The tree \(T\) follows the convention that, at each node, all values stored in the left subtree of the node are smaller than the value stored at the node. You are not aware of the sequence in which these values were inserted into \(T\), and you do not have access to \(T\).Which one of the following statements is TRUE?
  1. A
    Inorder traversal of \(T\) can be determined from \(V\)
  2. B
    Root node of \(T\) can be determined from \(V\)
  3. C
    Preorder traversal of \(T\) can be determined from \(V\)
  4. D
    Postorder traversal of \(T\) can be determined from \(V\)

Solve it on GATE DA practice →More Basic Data Structures problems

Show the worked solutionOfficial GATE Answer Key: Option A.See full step-by-step discussion on GateOverflow: https://gateoverflow.in/422868/gate-cse-2024-set-2-question-29

GATE DA practice: past exam problems by chapter, with worked solutions · gatedaprep.com