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.
I recently purchased a new Velo-ton stationary bike and took it for a spin. The bike records three key metrics throughout the ride: cadence (how fast I’m riding), resistance (how hard I have to push the pedals to keep moving) and output (the power I produce).
With a little experimentation, I determine that the power (in watts) is equal to the product of the cadence and resistance values divided by 20. For example, if my cadence is 64 and my resistance is 25, then my power output is (64·25)/20, or 80 watts.
Whenever I ride, I always make sure that my resistance is between 20 and 60, while my cadence is between 60 and 100. After a particularly grueling 30-minute workout, I notice that my average resistance was 40, while my average cadence was 80. (Note that these averages are computed per unit of time, rather than per unit of distance traveled.)
At first, I figure my average power was (40·80)/20, or 160 watts. But I soon realize other values are also possible. What is the maximum average power that I could have produced? What is the minimum?
The solution to this Riddler Express can be found in the following column.
From Bradley Albrecht comes an ecologically minded enigma:
You are responsible for setting the ranger schedule at Riddler River National Park. Four rangers are assigned to two locations: the mountain lookout in the north and the lakeside campground in the south. Each assignment lasts one week (Monday through Friday), and every week two rangers should be in the north and two should be in the south.
Your task is to set an assignment schedule that lasts a certain number of weeks and then repeats indefinitely.
In the spirit of fairness, the rangers propose the following conditions for the schedule:
- Each ranger should spend as many weeks in the north as they do in the south.
- Each ranger should spend the same number of weeks paired with each other ranger.
- All rangers should move the same number of times over the course of the schedule. This includes potentially moving back to their starting assignment after the last week of the schedule.
- Exactly two rangers should switch locations each week.
What is the shortest possible repeating schedule that meets the rangers’ conditions?
The solution to this Riddler Classic can be found in the following column.
Solution to last week’s Riddler Express
Congratulations to 👏 Toby Frager 👏 of San Leandro, California, winner of last week’s Riddler Express.
Last week, while watching batter spread out on my waffle iron, I noticed the following sequence of numbers:
1, 4, 4, 0, 4, 8, 0, 0, 4, 4, 8, …
For the full Riddler experience, I urged you to not look up this sequence in the On-Line Encyclopedia of Integer Sequences. After you figured out the next few terms in the sequence, your task was to figure out the average value of the entire sequence.
Let’s start with the sequence. There were plenty of zeros, fours and eights, but why were they arranged in this particular order?
The real clue was the batter spreading out on a waffle iron. These were the number of points on a lattice (i.e., a waffle iron) that would be covered by a growing circle (i.e., the spreading batter). The animation below shows the sequence in action:
You could also generate the sequence algebraically. Any point (x, y) on a circle centered at the origin must satisfy an equation of the form x2 + y2 = N, where the radius of the circle is √N. The first term in the sequence turned out to be the number of lattice points with x2 + y2 = 0. There was only one such point: (0, 0).
Meanwhile, there were four points with x2 + y2 = 1: (1, 0), (−1, 0), (0, 1) and (0, −1). Similarly, there were four points with x2 + y2 = 2, zero points with x2 + y2 = 3, four points with x2 + y2 = 4, eight points with x2 + y2 = 5, and so on. The last term in the sequence given above — 8 — corresponded to the eight points with x2 + y2 = 10. After the values listed in the original problem, the next few terms in the sequence were 0, 0, 8, 0, 0, 4, 8, 4, etc.
As fascinating as this was, the riddle asked for the average value of the entire sequence, rather than the sequence itself. The average of the first 11 given terms was 37/11, or about 3.3636. According to the OEIS, the average of the first 102 terms was about 3.1863. As noted by solver Praveen Anumolu, this value was suspiciously close to 𝜋. Could that have been the answer?
Indeed it was. And here, visualizing the ever-expanding waffle was helpful. For very large values of N, the sum of the first N terms in the sequence was approximately the number of lattice points within the circle x2 + y2 = N. And this, in turn, could be approximated by the area of the circle. Since the radius of the circle was √N, the area was 𝜋(√N)2, or 𝜋·N. Finally, the average of the sequence was the total sum (𝜋·N) divided by the number of terms (N).
Yes, the answer was 𝜋. And yes, I had some pie after finishing off my waffles.
Solution to last week’s Riddler Classic
Congratulations to 👏 Emma Knight 👏 of Toronto, Canada, winner of last week’s Riddler Classic.
Last week, you again grappled with the new Olympic event of sport climbing.
This time, the finals of the sport climbing competition had eight climbers, each of whom competed in three different events: speed climbing, bouldering and lead climbing. Based on their time and performance, each of the eight climbers was given a ranking (first through eighth, with no ties allowed) in each event, as well as a corresponding score (1 through 8, respectively).
The three scores each climber earned were then multiplied together to give a final score. For example, a climber who placed second in speed climbing, fifth in bouldering and sixth in lead climbing would have received a score of 2 × 5 × 6, or 60 points. The gold medalist was whoever achieved the lowest final score among the eight finalists.
What was the highest (i.e., worst) score one could achieve in this event and still have a chance of winning (or at least tying for first place overall)?
A good first step was to determine an upper bound, beyond which defeat was certain. You also knew that the product of all eight competitors’ scores had to equal the product of all 24 event scores, which was (8!)3. So to find that upper bound, you could consider the case when all eight climbers had the exact same score x. This meant x8 was equal to (8!)3, which meant x was approximately 53.34. In other words, there was no way that all eight competitors could have scores greater than 53 — the winner had to have 53 or fewer points.
However, there was no way to multiply three numbers from 1 to 8 such that they would equal 53, a prime number. Meanwhile, 52 had a largest prime factor greater than 8 (i.e., 13), as did 51 (17). The next few scores to consider were 50, 49 and 48.
To score 50, the winner had to earn event scores of 2, 5 and 5. Now consider the three climbers who won the three events. Since we wanted their scores to all be at least 50, they needed to come in seventh and eighth in their other two events. This meant the remaining five climbers (including our supposed winner) all had to finish between second and sixth in each event. Next, consider the other two climbers who finished second in an event. For them to also score at least 50, they had to come in fifth or sixth in their other two events. At this point, the final two climbers had to come in third or fourth in all three events. The only way to multiply three threes or fours together to get at least 50 was 4 × 4 × 4 = 64, which meant the final climber scored 3 × 3 × 3 = 27 — a value that was not greater than 50. Given this contradiction, the winner must have scored lower than 50.
Next, let’s see what happened when one of the climbers scored a 49, which required earning 1, 7 and 7 points in the three events. Like before, we can consider the other two climbers who won an event. To score at least 49, they had to come in seventh or eighth in the other two events. And once again, the remaining five climbers all had to finish between second and sixth in each event. The three climbers who came in second in an event also had to come in fifth or sixth in their other two events to score at least 49. And so you were left with two climbers who had to come in third and fourth in all three events, leading to the exact same contradiction.
With 50 and 49 both impossible, that left 48. And sure enough, a climber could tie for first place overall with 48 points. Solver Rolan Shomber found one such way this could happen, with the following eight scores:
- 1 × 6 × 8 = 48
- 1 × 6 × 8 = 48
- 1 × 6 × 8 = 48
- 2 × 5 × 5 = 50
- 2 × 4 × 7 = 56
- 2 × 4 × 7 = 56
- 3 × 4 × 5 = 60
- 3 × 3 × 7 = 63
For this particular solution, there was a three-way tie for first. With a winning score of 48, it was also possible for there to be a two-way tie for first. But to win outright, several solvers like Paige Kester and this week’s winner, Emma, found that the highest first-place score was 45.
So while it was possible to tie for the win with an overall score of 48, how likely was this to happen? As it turned out, not very. Solver Angelos Tzelepis ran millions of simulations, finding that only a small handful of them resulted in a first-place score of 48:
In Tokyo, the gold medalists in the women’s and men’s competitions respectively earned 5 points (wow!) and 28 points. But I have to admit, a drama-laden tie at 48 would have been fun to watch.
Want more riddles?
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.