🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: Heaps and Heap Sort Internals: all 15 questions

Quiz: Heaps and Heap Sort Internals · Question 2 of 15

What is the parent index of the node at index 6?

What is the parent index of the node at index 6?

  1. A.3
  2. B.1
  3. C.2
  4. D.4
Answer & explanation

Correct answer: 2

(6 − 1) // 2 = 2. Index 5 also has parent 2.

Can you get the rest right without peeking?

Take the timed Quiz: Heaps and Heap Sort Internals quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →