Question DSA-TREE-0050
MediumIn a complete binary tree stored in an array from index 1, where are the children of node i?
- A.
2i and 2i + 1
- B.
2i − 1 and 2i
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Trees question
In a complete binary tree stored in an array from index 1, where are the children of node i?
2i and 2i + 1
2i − 1 and 2i
Sign up free to see the answer and a step-by-step explanation.
i + 1 and i + 2
i/2 and i/2 + 1