Skip to content

Problem 1

Suppose Bob starts with 1 credit. Everyday Bob can choose to go to a casino. On Day ii (with ii starting from 1), he has a 101−i100\frac{101-i}{100} chance to win his gambling. If he wins, he wins a prize of 12i\frac{1}{2^i} credits. If he loses, then he loses all of the credits accumulated so far, and he has no more money to gamble anymore. Optimally, how many days of gambling should Bob do?

Solution

Answer: 44 days

Consider the marginal profit from each day. Bob should continue only while the expected marginal profit is positive; otherwise, the expected amount of money he has decreases.

On day ii, the expected revenue is 101−i100⋅12i\frac{101-i}{100}\cdot\frac1{2^i}. His accumulated money before that day is 1+12+⋯+12i−1=2−12i−11+\frac12+\cdots+\frac1{2^{i-1}}=2-\frac1{2^{i-1}}, so the expected loss is i−1100(2−12i−1)\frac{i-1}{100}\left(2-\frac1{2^{i-1}}\right).

Marginal profit=101−i100⋅2i−i−1100(2−12i−1)=99+i−(i−1)2i+1100⋅2i.\text{Marginal profit}=\frac{101-i}{100\cdot2^i}-\frac{i-1}{100}\left(2-\frac1{2^{i-1}}\right)=\frac{99+i-(i-1)2^{i+1}}{100\cdot2^i}.

This is positive only for i≤4i\leq4. Thus, optimally, Bob should gamble for 44 days.