GATE / CS ARCHIVE

GATE CSE 2025 SET 1 / QUESTION 10

Counting unordered ice-cream scoops

General Aptitude · Counting, Probability & Sets · Full GATE CSE 2025 Set 1 paper

GATE 2025 Set 1, Q10 2 marks · MCQ
Report issue

Counting, Probability & Sets

Question 10, GATE 2025: There are four distinct ice-cream flavours. Buy exactly three scoops, allowing repeats, and regard purchases differing only in scoop order as identical. How many purchases are possible? A 4; B 20; C 24; D 48.
Tap to enlarge
Your answer
Answer & solution

Official answer: B

Approach: Represent a purchase by the number of scoops of each flavour, not by an ordered sequence.
Let x1,x2,x3,x4 be the non-negative integer counts. Every purchase corresponds uniquely to x1+x2+x3+x4=3. With three stars for scoops and three separators for the four flavours, stars and bars gives C(3+4−1,4−1)=C(6,3)=20, option B.
An independent case count checks this: three identical scoops give 4 choices; a pair of one flavour plus a different flavour gives 4×3=12 choices; three different flavours give C(4,3)=4 choices. Total 4+12+4=20.
Using 4³ would count ordered selections and overcount many purchases. Using only C(4,3) would forbid repeated flavours, contrary to the question.

Original paper, page 10 · Answer key