GATE Computer ScienceVery hardNIELIT Scientist B

How many solutions does x₁ + x₂ + x₃ + x₄ = 15 have in integers with 0 ≤ xᵢ ≤ 6 for every i?

  1. A. 160
  2. B. 200
  3. C. 140
  4. D. 180

Correct answer: D. 180

Inclusion–exclusion: C(18,3) − 4·C(11,3) + 6·C(4,3) = 816 − 660 + 24 = 180.

More Discrete Mathematics questions

Exams that ask this topic