Cricket header

Ruby Redfort's Spy Mystery

A Puzzle with a Fatal Flaw

At 6:45am yesterday, I - and about a million other listeners - heard the following puzzle being read out on BBC Radio 4's Today programme:

Spectrum HQ has been surrounded and there is no way to bring in more food. The trapped agents will have to survive on what they’ve got inside. 40 agents would have enough food for 20 days. 30 agents would have enough food for 30 days. How long will the food sustain 25 agents?

The puzzle comes from the Spectrum spy exam in Lauren Child's Ruby Redfort books for children.  Have a mull and see if you can come up with an answer, before reading the (ahem) 'solution' below.

       *                       *                      *                         *                          *                          *

At first glance this puzzle looks like it might be quite easy. 

40 agents and 20 days, 40+20=60....30 agents and 30 days, 30+30=60....hey, the two numbers always add up to 60.  So since 25+35=60, then 25 agents will have food for 35 days.  Solved!

But before we close the case, let's think about this for a moment. What if there are 60 agents?  60+0 = 60, so this means the 60 agents would have food for Zero days.  This makes no sense - we know there's some food, so it's going to last for a few days at least.

OK, maybe this puzzle isn't so easy.

Let's go back to first principles:

We are told that 40 agents have enough food for 20 days.  So if there was only one agent instead of forty agents, this food would last the single agent 40 times as long.  In fact it would last her 40 x 20 = 800 days, more than two years.

Wait, not so fast!  We are also told that 30 agents have enough food for 30 days.  So now we are being told there is enough food to last a single agent 30x30 = 900 days.  This doesn't make sense, first we are told there is enough food to last a single agent 800 days, then we are told there's enough to last her 900 days.

OK, there is something strange going on here. I've been assuming that agents all eat food at the same rate.  Maybe that's not true.  But in that case this becomes a horribly complicated problem with lots of possible answers.  Aargh!!!!

I spent about half an hour scratching my head on this and then I gave up, and looked up the answer on Ruby Redfort's exam solution sheet.

And the answer given was...40 days.  Really?  Where did that come from?

I'm not even going to attempt to explain the reasoning in the published solution (because I disagree with it), but in essence we are expected to figure out a formula that connects D, the number of days that the food will last and A, the number of  agents.  Here is the formula that their solution was based on:

                                   D = 600 / (A - 10)

Let's stick the numbers into the formula to check:

             If A is 40, then D = 600/30 = 20

             If A is 30, then D = 600/20 = 30

             And if A is 25, then D = 600/15 = 40

Hooray, these match the numbers in the puzzle!

But does the formula and the answer of 40 days for 25 agents make sense?  What if the puzzle had instead asked how long the food will last if there are ten agents?  Stick A=10 into the formula and you discover that the number of days that the food will last is 600 divided by Zero.  And if you divide by zero you get infinity. Which means the food will last forever!

This is patently nonsense.  And it means that the formula on which the published solution is based must be wrong.  Or at least, that's what I thought until my friend David Acheson* from Oxford University came up with an ingenious explanation.

"I think I know what's going on," he said. "Ten of the agents don't eat anything. That's because they're dead". ** 

Genius.  As long as we assume that there are ten dead agents, while the rest of the agents all eat at exactly the same rate, then the solution of 40 days is fine. 

And if you figured that out, you should probably apply for a job at the Spectrum Spy Agency.


* David Acheson is the author of two wonderfully accessible maths books, '1089 And All That' and 'The Calculus Story'.  Read them!

** Or it's possible that ten of the agents have brought their own secret supply of food which they aren't sharing.