3 ms·
If you start with k cans in the fridge, you take one there is now k-1 cans in the fridge, you add back two, according to the rule, there are now k+1 can in the
by GistNoesis 4y ago
If you start with k cans in the fridge, you take one there is now k-1 cans in the fridge, you add back two, according to the rule, there are now k+1 can in the fridge.
You and your colleagues repeat this process n times, n being the number of total cans drank. At the end of the repeating n times there are k+n cans in the fridge, and n cans in the garbage bin.
- bitshiftfaced 4y agoIf you look at it that way, then the daily growth is only linear when the daily n is constant. When the daily n = number of cans to start with that day, then the daily growth is 2^n.