CARDS
CodeChefOpen on judge ↗
Rishabh loves to play with cards and puzzles, Today he is trying something new with cards and poses a question for you. Can you solve it? Rishabh has $N$ cards. On the $i$-$th$ $(1≤i≤N)$ card is written an integer $xi$. He is selecting one or more cards from these $N$ cards, so that the average of the integers written on the selected cards is exactly $A$. In how many ways can he make his selectio
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start