1) There are two indistinguishable opaque jars that each contain 100 pieces of candy. People randomly choose one of the jars and reach in to pull out a piece of candy. When someone first discovers the jar they reached into is empty, how many pieces of candy would you expect to be in the other jar?
2) What is the relationship between the number of pieces of candy originally in each jar and the expectation?
The reason this problem actually came to mind is because I have two identical canisters of salt in my kitchen and I'm wondering if by serendipity it's a brilliant earlywarning system that I need to go buy another two canisters. It's not a precisely accurate model, since the amount of salt I use varies from instance to instance, but it should be close enough for government work.
2 jars of candy
Moderators: jestingrabbit, Moderators General, Prelates

 Posts: 286
 Joined: Tue Aug 22, 2006 10:35 pm UTC
 Contact:
Re: 2 jars of candy
Spoiler:
Edit: spoiler'd
Last edited by GreedyAlgorithm on Tue Oct 25, 2011 7:31 pm UTC, edited 1 time in total.
GENERATION 1i: The first time you see this, copy it into your sig on any forum. Square it, and then add i to the generation.
 skeptical scientist
 closedminded spiritualist
 Posts: 6142
 Joined: Tue Nov 28, 2006 6:09 am UTC
 Location: San Francisco
Re: 2 jars of candy
Since neither solution so far includes a nice formula for the general case, I'll post mine:
Spoiler:
I'm looking forward to the day when the SNES emulator on my computer works by emulating the elementary particles in an actual, physical box with Nintendo stamped on the side.
"With math, all things are possible." —Rebecca Watson
"With math, all things are possible." —Rebecca Watson

 Posts: 286
 Joined: Tue Aug 22, 2006 10:35 pm UTC
 Contact:
Re: 2 jars of candy
Wolfram Alpha can do it even if Google can't! And you're right, the difference is exactly in whether we stop when emptying a salt shaker or when first trying to use a previously emptied salt shaker.
Spoiler:
GENERATION 1i: The first time you see this, copy it into your sig on any forum. Square it, and then add i to the generation.
Re: 2 jars of candy
I decided to take a simpler, almost "fagpacket calculation" approach to this one, giving me a very different result to those above!
Spoiler:
Who is online
Users browsing this forum: No registered users and 7 guests