Can You Game The Currency Exchange?
Welcome to The Riddler. Every week, I offer up problems related to the things we hold dear around here: math, logic and probability. Two puzzles are presented each week: the Riddler Express for those of you who want something bite-size and the Riddler Classic for those of you in the slow-puzzle movement. Submit a correct answer for either,1 and you may get a shoutout in the next column. Please wait until Monday to publicly share your answers! If you need a hint or have a favorite puzzle collecting dust in your attic, find me on Twitter or send me an email.
As a citizen of Riddler Nation, you are visiting the United States. Upon landing at an American airport, you would like to exchange your 100 Riddlerian rupees for some American currency. Fortunately, you notice a currency exchange station where it might just be possible to make a profit.
The dollar is known to be more valuable than the rupee. Now this station says they will give you D dollars for each rupee, where D is a decimal less than 1 that goes to the hundredths place. So D can be 0.99, 0.50 or 0.37, but not values like 0.117 or 1/𝜋. And when exchanging dollars back into rupees, the station uses an exchange rate of R, where R is equal to 1/D rounded to the nearest hundredth. (Yes, that last part is very important.)
For example, suppose D is 0.53. In this case, when you trade in 100 rupees, you’ll receive $53. When trading the $53 dollars back, the station uses an exchange rate of 1/0.53, or 1.88679…, which they round up to 1.89. And so returning the $53 gets you 100.17 rupees — a net profit!
What value of D will earn you the greatest profit for your 100 rupees? (Remember, D is a decimal that goes to the hundredths place and is less than 1.)
From Dave Moran comes a practical parking puzzle:
There’s a parking lot behind Dave’s office building with 10 spaces that are available on a first-come, first-serve basis. Those 10 spaces invariably fill by 8 a.m., and the parking lot quickly empties out at 5 p.m. sharp.
Every day, three of the 10 “early birds” who snagged spots before 8 a.m. leave at random times between 10 a.m. and 3 p.m. and do not return that day. Knowing that some early birds leave during that five-hour window, nine “stragglers” drive by the lot at random times between 10 a.m. and 3 p.m. If there’s an available spot, a straggler immediately parks in the spot and doesn’t leave until 5 p.m. If there’s no open spot, a straggler immediately drives away from the lot and parks somewhere else, and doesn’t return that day.
Suppose you are a straggler arriving at a random time between 10 a.m. and 3 p.m. What is the probability that you will get a spot in the lot?
Solution to the last Riddler Express
Congratulations to 👏 Billy Mullaney 👏 of Minneapolis, winner of last week’s Riddler Express.
In advance of the 2013-14 season, the NBA changed the format of the NBA Finals, a best-of-seven series. Previously, the Finals used a “2-3-2” format: Games 1, 2, 6 and 7 were played in the home arena of the higher-seeded team, while Games 3, 4 and 5 were in the arena of the lower-seeded team. With the change, the Finals moved to the “2-2-1-1-1” format: Games 1, 2, 5 and 7 were at the home of the higher-seeded team, while games 3, 4 and 6 were at the home of the lower-seeded team.
Last week, you were playing for the higher-seeded team heading into the Finals. While your team had a better record during the regular season, the two teams were evenly matched — at a neutral site, both teams were equally likely to win a game. But of course, no game in the Finals is played at a neutral site. Both teams had a 60 percent chance of winning each home game and a 40 percent chance of winning each away game.
Which format — 2-3-2 or 2-2-1-1-1 — gave your team a better chance of winning the Finals? (Or were they the same?)
A few solvers, like Emily Kelly, worked through the details, but that turned out to not be necessary with some careful thinking up front. We tend to break down best-of-seven series into different cases depending on how many games are played, which could be four, five, six or seven, each with different probabilities of occurring. But another way to imagine all this would be for the two teams to play all seven games, even if one of the teams has already won four of them. Playing those potentially extra games would have no effect on either team’s probability of winning the series, since the first team to win four of seven must be the only team to win four of seven.
So if you imagine playing all seven games no matter what, four of which are at home and three of which are on the road, then the ordering of which games are at home and which are on the road will have no effect on your chances of winning. Therefore, both formats (the 2-3-2 and the 2-2-1-1-1) gave you the same chance of winning.
For that matter, the series could have been 1-1-1-1-1-1-1 (alternating home and away with each game), 4-3 (the first four games at home) or 3-4 (the last four games at home). None of this mattered — all 7 choose 4 (or 35) arrangements gave you the same chance of winning the series.
For extra credit, you had to determine that chance of winning. This time around, working through the details like Emily did was required. Again, it may have been simpler to imagine you played all seven games rather than stopping as soon as one team won four of them. In the end, your probability of winning was 8,313/15,625, or about 53.2 percent.
Interestingly, when the home team had a 50+x percent chance of winning, then your chances of winning the series varied nonlinearly with x. For small values of x, the probability of a series win hovered closer to 50 percent. We already said you had a 53.2 percent chance of winning the series when the home team won 60 percent of the time. When the home team won 70 percent of the time, you won the series about 57 percent of the time. When the home team won 80 percent of the time, you won the series about 62.6 percent of the time. When the home team won 90 percent of the time, you won the series about 73.6 percent of the time. But when the home team won 100 percent of the time, home-court advantage meant you were guaranteed to win the series.
Solution to the last Riddler Classic
Congratulations to 👏 Matthew Pitcock 👏 of Chicago, winner of last week’s Riddler Classic.
Last week, you started with just the number 1 written on a slip of paper in a hat. You were going to draw from the hat 100 times, and each time you drew, you had a choice: If the number on the slip of paper you drew was k, then you could either receive k dollars or add k higher numbers to the hat.
For example, if the hat contained slips with the numbers 1 through 6 and you drew a 4, you could have either received $4 or received no money but added four more slips numbered 7, 8, 9 and 10 into the hat. In either case, the slip with the number 4 would have then been returned to the hat.
If you played this game perfectly — that is, to maximize the total amount of money you’d receive after all 100 rounds — how much money would you have expected to receive on average?
What made this puzzle interesting was the apparent tension between your choices: At each stage, did it make more sense to cash out what you could, or were you better off reinvesting and putting larger quantities into the hat, potentially boosting your earnings later on? Most solvers tackled this tension by working backward from when there were only a few rounds remaining.
Suppose you were drawing for the 100th (and last) time and that there were N numbers in the hat. Since this was your final chance to extract some cash from this game, you always took the money rather than put more numbers into the hat. You could expect to receive the average of the numbers from 1 to N, or (N+1)/2 dollars.
Now suppose you were drawing for the 99th time. Again, suppose there were N numbers in the hat (perhaps a different value from the N in the previous paragraph) and that you drew the number k. If you pocketed the money, you’d get k dollars this round and then an average of (N+1)/2 dollars in the final round, for a total average of k+(N+1)/2. But if you put k more numbers into the hat, you’d get zero dollars this round and an average of (N+k+1)/2 dollars in the final round. Since k+(N+1)/2 was always greater than (N+k+1)/2, you were better off taking the money here. In the end, you could expect to receive the average of k+(N+1)/2 for all values of k from 1 to N, which was N+1 dollars.
Next, suppose you were drawing for the 98th time. Once again, suppose there were N numbers in the hat and you drew the number k. If you took k dollars, your expected total after 100 drawings would have been k+N+1. If you instead added k more numbers to the hat, your expected total after 100 drawings would again have been k+N+1, the exact same result! So on the 98th drawing, it didn’t matter if you took the money or added more numbers to the hat. Either way, your expected final total was (3/2)·(N+1) dollars.
And now suppose you were drawing for the 97th time, with N numbers in the hat and a drawn number k. If you took the money, your expected total was k+(3/2)·(N+1). If you added k more numbers to the hat, your expected total was (3/2)·(N+k+1). This time around, you got more money on average by adding numbers to the hat, resulting in an expected total of (3/2)2·(N+1) dollars.
Putting more numbers in the hat was also the better option when you drew for the 96th time, the 95th time, the 94th time and so on, with each prior drawing adding another factor of 3/2 to your expected total.
To summarize, you could maximize your expected earnings by always putting more numbers into the hat (regardless of what value k you drew) for the first 97 drawings. For the 98th, it didn’t matter if you took the money or added more numbers to the hat. And for the last two drawings, you took the money. In the end, your expected total winnings were (3/2)98·(1+1), or about 361.4 quadrillion (with a Q!) dollars. For reference, this figure exceeded the annual GDP of the world by a few thousandfold.
Solver Laurent Lessard further explored the distribution your winnings could take when you played to maximize the average. The distribution had a log-normal appearance, which was why the arithmetic mean appeared to the right of the maximum. While you made 361.4 quadrillion dollars on average, you usually made less than that (and sometimes a lot more).
Want more puzzles?
Well, aren’t you lucky? There’s a whole book full of the best puzzles from this column and some never-before-seen head-scratchers. It’s called “The Riddler,” and it’s in stores now!
Want to submit a riddle?
Email Zach Wissner-Gross at email@example.com.