Expected Sum
There are $N$ chits, out of which, $A$ chits have $1$ written on them and $B$ $(A+B = N)$ chits have $0$ written on them. Chef and Chefina are taking alternate turns. They both have a personal score which is initially set to $0$. Chef starts first. On their turn, a player will: - Pick a random chit among the available chits; - Add the number written on the chit to their personal score; - Remove t
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