• recategorized by
133 views
1 1 vote

The preorder traversal of a Binary Search Tree (BST) is given as$: 15, 10, 12, 11, 20, 18, 16, 22.$ Which of the following statements is/are CORRECT?

  1. The postorder traversal of the tree is $11, 12, 10, 16, 18, 22, 20, 15.$
     
  2. The root of the left subtree of the node with value $\mathrm{2 0}$ is $\mathrm{1 8}$.
     
  3. The inorder traversal is $10, 11, 12, 15, 16, 18, 20, 22.$
     
  4. The tree is a Complete Binary Tree.

1 Answer

Answer:
Position:
Show:

Related questions

1 1 vote
1 1 answer
170
170 views
GO Classes asked Feb 20
170 views
Consider the Merge Sort algorithm applied to an array $A$ of $n$ distinct integers. During the Merge step, we maintain two pointers for the sorted subarrays $L$ and $R$. ...
1 1 vote
1 1 answer
154
154 views
GO Classes asked Feb 20
154 views
Consider a directed weighted graph $G$ with $V$ vertices and $E$ edges. The weights are all positive integers. If we increase the weight of every edge by a constant value...
3 3 votes
1 1 answer
131
131 views
GO Classes asked Feb 20
131 views
Consider the Quicksort algorithm applied to an array of $n$ distinct elements. The pivot is always chosen as the median of the first, middle, and last elements of the cur...
0 0 votes
1 1 answer
190
190 views
GO Classes asked Feb 20
190 views
Let $S$ be a stack of size $n$ and $Q$ be a queue of size $n$. An algorithm performs the following sequence of operations:Push elements $1,2, \ldots, n$ into stack $S$ in...