ProgrammingHardTCS CodeVita · Infosys HackWithInfy

What is printed?

What is printed?
from math import comb
print(comb(4, 2) * comb(4, 2), comb(8, 4) - comb(8, 3))
  1. A. 16 14
  2. B. 12 14
  3. C. 36 14
  4. D. 36 13

Correct answer: C. 36 14

comb(4, 2) = 6, so the product is 36. comb(8, 4) = 70 and comb(8, 3) = 56, so the difference is 14.

More Python Programming questions

Exams that ask this topic