Queen Elizabeth’s School has won a national online Mathematics competition, beating off the challenge of hundreds of other schools.

The winning team, made up of four sixth-formers, dropped just one point in the eight rounds of the University of Manchester’s MathsBombe, scoring 119 points out of a possible 120.

Headmaster Neil Enright: “My congratulations go to this team on an almost perfect performance. The competition attracted a large field of teams from leading schools across the state and the independent sectors, and it demanded both speed and deep mathematical understanding. This victory therefore represents a considerable achievement.”

The winning team comprised Year 12 pupils Bashmy Basheer, Kishan Patel, Nico Puthu and Niam Vaishnav. Notwithstanding the team’s name,* maiNlyNiam*, Kishan was the captain.

Organised by the university’s Mathematics department and supported by the Dame Kathleen Ollerenshaw Trust (a charity named after a mathematician and Lord Mayor of Manchester, who died in 2014 aged 101), the competition attracted entries from more than 600 schools.

From January, every two weeks a new set of problem was released online. The puzzles spanned the whole spectrum, from logic puzzles in pure Mathematics to applications of Mathematics in real-world settings.

The maximum 15 points were available to the first team to solve the problem and to other teams solving it within an hour of the first team. Other points were awarded on a sliding scale, depending on the time taken to solve each problem. The rules forbade any assistance from teachers and also prohibited collaboration between teams.

An online leaderboard enabled teams to keep track of their progress throughout the duration of the event. Kishan said this proved to be a spur to his team’s success: “The competition from the other teams encouraged us to answer the questions as quickly as possible.” Niam added that the four friends had enjoyed the opportunity to tackle challenging problems that differed from those they normally faced in the classroom.

Other teams entered by QE also performed creditably, with one, BombVoyage, taking 43rd place, having solved six of the eight puzzles and scored 70 points.

**Here is an example of** one** of the problems, with the solution below:**

Grobnog the Goblin King was sitting on his throne consulting with Torqmaga the Inquisitor. “Your Majesty, we’ve been infiltrated by a rogue group of Goblins,” said Torqmaga. “They call themselves Nilbogs. Physically they are identical to Goblins, but – unlike true Goblins – they always tell the truth.”

“Our whole society is founded on Goblins being evil and lying whenever they can!” said Grobnog. “We need to identify these interlopers!”

Torqmaga handed over a piece of paper. “I’ve tortured all of your subjects to find out who is a Goblin and who is a Nilbog. I can assure you that under my questioning, everybody was true to their real nature: every Nilbog told the truth and every Goblin lied.”

Grobnog inspected the list. “What does ‘or’ mean here? Does it mean ‘one or the other or both’?” he asked.

Torqmaga nodded. “Yes, your Majesty, it’s the logical meaning of the word ‘or’. It seems that torture turns Goblins and Nilbogs into very logical monsters. I’m sure you can work out from their statements below who is a Goblin and who is a Nilbog.”

Agmiz “Fragdag would definitely say that I’m a Goblin.”

Bord “Exactly one of Iz and Molk is a Nilbog.”

Cherguff “Those good-for-nothing layabouts Dolk and Lold are the same type of monster as Molk.”

Dolk “Stop the torture! Bord and Yobblot are both Nilbogs or both Goblins!”

Erkaz “I may hate his guts, but Toxplok and I are the same type of monster.”

Fragdag “Quonk and Xinik are Nilbogs.”

Gneeg “Zisbut and I are different types of monster.”

Hrunk “Gneeg is most definitely a Goblin.”

Iz “Molk is a Nilbog and deserves everything Grobnog will do to him.”

Jop “Bord would say that Fragdag is a Nilbog.”

Klaatak “Lold is a traitorous Nilbog!”

Lold “Ronx is a loyal Goblin! Will you let me off the rack now?”

Molk “Erkaz never tells me the truth, she’s a typical Goblin.”

Norbet “All I’ll say is that Wizmok is a Goblin or Zisbut is a Nilbog.”

Oinq “Agmiz and Quonk are loyal to Grobnog! They’re both Goblins!”

Plegkurk “Dolk and Hrunk are either both Nilbogs or both Goblins.”

Quonk “Oinq, if he ever stopped eating, would say that I’m a Nilbog.”

Ronx “Xinik and Bord are both evil Nilbogs.”

Squee “Lold is a typical Goblin – he owes me 200 silver pennies!”

Toxplok “That little toerag Cherguff would say I’m a Nilbog.”

Udonk “Iz would say that Ronx was a Goblin.”

Vuird “Ronx would say that Udonk is a Nilbog.”

Wizmok “What can I say? Iz is a Nilbog or Norbet is a Goblin. Will that do?”

Xinik “I know that if you ask Ronx then he’d say Squee is a Nilbog.”

Yobblot “Klaatak and Squee are both Goblins.”

Zisbut “Hrunk is a goblin — the most disgusting I’ve ever met.”

Your task is to work out which of the 26 monsters above are goblins and which are nilbogs.

Enter your answer as a sequence of 26 letters: G (for Goblin), N (for Nilbog) arranged in the order of the 26 goblins/nilbogs listed above. If you think that Agmiz is a Nilbog, Bord is a Nilbog, Cherguff is a Goblin, Dolk is a Nilbog, …, Zisbut is a Goblin then you should enter your answer as NNGN…G.

**Solution:**

Refer to each Goblin or Nilbog by the first letter of its name. If a monster is a Goblin then we’ll write that it always lies; if the monster is a Nilbog then we’ll write that it tells the truth. By saying two monsters are the same we mean that they are either both Goblins or both Nilbogs.

The clues are then:

A: F says A always lies

B: Exactly one of I, M tells the truth

C: D and L are the same as M

D: B = Y

E: T = E

F: X and Q tells the truth

G: Z != G

H: G always lies

I: M tells the truth

J: B says F tells the truth

K: L tells the truth

L: R always lies

M: E always lies

N: W always lies or Z tells the truth

O: A and Q both always lie

P: D = H

Q: O would say Q tells the truth

R: X and B both tell the truth

S: L always lies

T: C would say T tells the truth

U: I would say R always lies

V: R would say U tells the truth

W: I tells the truth or N lies

X: R would say S tells the truth

Y: K and S both always lie

Z: H always lies

1. Consider clue I. If I is telling the truth then M always tells the truth. If I is lying then M is lying. Hence I = M (but we don’t know whether they both lie or both tell the truth).

2. Clue B says that I != M. Hence B is lying.

3. Clue R says that B tells the truth. Hence R must be lying. (Note that we can’t say anything about X from clue R.)

4. Clue L says that L must be telling the truth. Hence K is also telling the truth (K’s clue) and S is lying (S’s clue).

5. Clue Y says that both K and S both lie. But K tells the truth. So Y is lying. As both B and Y are lying, Clue D is true; hence D tells the truth.

6. Consider clue X. Suppose that X lies. If X is lying then R would actually say that S lies. We know that R lies, this would actually mean that S tells the truth. But we know S lies, so our assumption that X lies is wrong. Hence X tells the truth.

7. Consider clue F. Suppose that F is telling the truth. Then clue F tells us that X tells the truth (we already knew this) and Q tells the truth. Clue Q then tells us that O would say that Q is telling the truth (which indeed Q is), so O must also be telling the truth. Clue O tells us that both A and Q both lie. But this contradicts the fact that we’ve just argued that Q is telling the truth. Hence our assumption that F is telling the truth is wrong, so F must be lying.

8. As F is lying, it’s not true that both X and Q tell the truth. We know that X does tell the truth. So this tells us that Q must be lying.

9. Knowing that Q is lying, clue Q tells us that O would actually say that Q lies. This is indeed the case, hence O is telling the truth.

10. Clue O now tells us that A lies.

11. Consider Clue J. We know B lies. As F lies, B would indeed say that F told the truth. Hence J is making a true statement, so is telling the truth.

12. Consider Clue M. We’ll consider the two cases (M tells the truth, M lies) separately. First suppose that M tells the truth. Then E must lie. Clue E says that T and E are different, hence T must tell the truth. Now consider the other case where M lies. In this case, clue M says that E is telling the truth; it then follows from clue E that T is also telling the truth. Hence, no matter whether M is telling the truth or lying, we must have that T is telling the truth.

13. Clue T tells us that C is making a true statement. Hence C tells the truth.

14. Clue C tells us that M is the same as D and L (who are both telling the truth). Hence M is telling the truth. Clue M then tells us that E is lying.

15. Clue I is making a true statement about M. Hence I tells the truth.

16. Consider clue U. Monster I tells the truth, and R does indeed lie. Hence U is telling the truth.

17. Consider clue V. Suppose V tells the truth. Then R would indeed say that U tells the truth. We know that R lies, so this would mean that U lies. But U tells the truth, a contradiction. Hence V must lie.

18. Consider clue Z. Suppose Z tells the truth. Then H lies. Clue H then tells us that G tells the truth. Clue G tells us that Z and G are different. But we’ve just argued that both Z and G tell the truth, a contradiction. Hence Z must lie.

19. Clue Z then tells us that H tells the truth.

20. Clue H then tells us that G lies. (Just to check: G lies, so clue G tells us that both Z and G are the same, which indeed they are.)

21. As both D and H tell the truth, clue P implies that P tells the truth.

22. Consider clue W. Suppose W always lies. Then clue W tells us that monster I always lies and N tells the truth. But we already know that monster I tells the truth, a contradiction. Hence W must tell the truth. (Note that, even though we know W tells the truth, clue W doesn’t tell us anything about whether N lies or not.)

23. Finally, consider clue N. If N is telling the truth then either W lies or Z tells the truth. But W tells the truth and Z lies, so neither of these possibilities can happen. Hence N must be lying.

Hence (denoting T for ‘telling the truth’ and L for ‘lying’) we can assign

ABCDEFGHIJKLM NOPQRSTUVWXYZ

LLTTLLLTTTTTT LTTLLLTTLTTLL

Reverting back to ‘Goblins always lie’ and ‘Nilbogs always tell the truth’ this gives

ABCDEFGHIJKLM NOPQRSTUVWXYZ

GGNNGGGNNNNNN GNNGGGNNGNNGG

so the required answer is GGNNGGGNNNNNNGNNGGGNNGNNGG