The number of different binary trees with 6 nodes is ______.

2016

The number of different binary trees with 6 nodes is ______.

  1. A.

    6

  2. B.

    42

  3. C.

    132

  4. D.

    256

Attempted by 552 students.

Show answer & explanation

Correct answer: C

Answer: 132

Method:

  1. Use the Catalan number formula for the number of different (rooted, ordered) binary trees with n nodes: C_n = 1/(n+1) * binom(2n, n).

  2. Substitute n = 6 to get C_6 = 1/7 * binom(12, 6).

  3. Compute the binomial coefficient: binom(12,6) = 924.

  4. Divide by 7: 924 / 7 = 132, so the number of different binary trees with 6 nodes is 132.

Explore the full course: Coding For Placement