Which of the following statements is false?

1998

Which of the following statements is false?

  1. A.

    A tree with n nodes has (n−1) edges

  2. B.

    A labeled rooted binary tree can be uniquely constructed given its post order and preorder traversal results.

  3. C.

    A complete binary tree with n internal nodes has (n+1) leaves.

  4. D.

    The maximum number of nodes in a binary tree of height h is 2^(h+1) − 1

Attempted by 124 students.

Show answer & explanation

Correct answer: B

Statement 1 is true because trees with n nodes have exactly n-1 edges.

Statement 2 is false because preorder and postorder traversals alone cannot uniquely reconstruct a binary tree without inorder traversal data.

statement 3 is also false.

Statement 4 is true.

A video solution is available for this question — log in and enroll to watch it.

Explore the full course: Gate Guidance By Sanchit Sir