GATE CS 2026, set 1 · Question 23 · Programming and Data Structures · Multiple select (MSQ) · 1 mark · no negative marks

Let n be an odd number greater than 100. Consider a binary minheap with n elements stored in an array P whose index starts from 1.
Which of the following indices of P do/does NOT correspond to any leaf node of the minheap?

  1. (A) (n+1)/2
  2. (B) (n-1)/2
  3. (C) (n-3)/2
  4. (D) n
Answer

Answer (B), (C)

Answer from the official GATE CS 2026 answer key.

The step-by-step solution, where available, is part of GATE CS Pro. See what Pro includes