GATE / CS ARCHIVE

GATE CSE 2015 SET 3 / QUESTION 25

GATE CSE 2015 Set 3 Q25

Discrete Mathematics · Combinatorics & Counting · Full GATE CSE 2015 Set 3 paper

GATE 2015 Set 3, Q25 1 mark · NAT
Report issue

Combinatorics & Counting

Question 25, GATE 2015: How many four-digit numbers can be made using only digits {1,2,3}, with digits in nondecreasing order from left to right? Repetition is permitted.
Tap to enlarge
Answer & solution

Official answer: 15

1. For example, counts (2,1,1) give exactly 1123, not its other permutations, because sorting is required. Distributing four identical positions among three digit counts is the weak-composition count (4+3−1 choose 3−1).

2. A nondecreasing four-digit sequence is determined by counts c1, c2, c3≥0 summing to 4. Stars and bars gives C(6, 2)=15, with one sorted sequence for every count triple.

Original paper, page 61 · Answer key