# Codebreakers

*This article for Primary and Secondary teachers is all about the mathematics behind solving puzzles, unravelling mysteries and breaking codes. For students, we hope that the tasks we have selected are intriguing and spark their curiosity. For teachers, it is about the mathematical skills we need to teach every day to enable our students to become confident mathematical thinkers.*

**What does it take to be a good maths detective and codebreaker?**

These features for Primary and Secondary fit particularly well with our Mathematical Habits of Mind. At NRICH we believe students learn better when we give them opportunities to be:

- Curious
- Resourceful
- Collaborative
- Resilient

To be a good maths detective, students need to think critically, to explain and justify the choices they make and become absorbed in the problem at hand; all the skills that a good mathematician needs. But above all, students need to be curious!

Good detectives also need to be able to work with others, so many of the problems we have selected encourage pair and group work. Being able to collaborate and communicate with others are essential skills for unlocking the mathematical mysteries in the features.

**Doing and undoing, working backwards**

Codebreakers need to have a good understanding of how something was encoded in order to be able to decode it. This embodies the mathematical skills of doing and undoing, and working backwards. Most actions have a corresponding action. For example, we get dressed in the morning and undressed in the evening. It is the same with mathematical tasks. With any doing, there is an associated undoing. Developing the skills of understanding inverse operations sets the foundations for algebraic thinking and equation solving. One strategy to use in the classroom is to give students the answer, and ask what was the question. With this approach, we can begin with simple questions and build up to more complicated ones.

For example:

I am thinking of a number. When I add 7, the answer is 9. What is my number?

I am thinking of a number. When I subtract 3, the answer is 9. What is my number?

I am thinking of a number. When I multiply by 2, then add 1, the answer is 9. What is my number?

I am thinking of a number. When I square it, then subtract 7, the answer is 9. What is my number?

You could ask:

How did you find the starting number?

What did you do to get the answer?

What is the connection between the question and the strategy you used?

Is there a pattern?

While students may begin by using a 'guess and check' strategy to solve these questions, they soon begin to see that they can use inverses to work backwards, or undo the actions to discover what was 'done' to the number in the first place.

An alternative to questions like these is 'The answer is... what might the question be?'

For example, we might choose to ask "What is the total of 4 + 8?", a closed question which gives students the experience of "doing". We could choose instead to write "10=?+?" and invite students to suggest possibilities. This question is much more open and gives students the opportunity to think mathematically, offers choice, and gives the experience of "undoing".

Being systematic is also a key skill for pupils to use if they are trying to sift through lots of information in trying to decide which is the most useful in solving the problem. Try not to show children how to record, but instead ask them to consider the merits of different approaches. They may need to modify their approach, reject one method for another and problem pose, as well as problem solve.

And of course, once they have solved one of the problems they can send it into the team to see if it can be published with other students solutions. Take a look at the article I've Submitted a Solution - What Next? to read about how we decide which solutions to publish.

**Alan Turing: mathematician, code breaker, detective**

This feature also offers the opportunity to introduce children to one of our great 20th Century mathematicians, who is probably best known for his work at Bletchley Park for his role in breaking the German Enigma code. So, why not create a display for children and parents on the importance of numbers, or ask students to research this famous mathematician, who spent most of his life being curious about numbers, processes and algorithms?

When Turing and his team worked on the Enigma code, all they had to work with was the encoded messages, the outputs intercepted from German transmissions, and a copy of the machine that was used to encode them. By working backwards, trying things out, making guesses and ruling out impossibilities, the team at Bletchley Park were able to work out the settings that the Enigma Machine used each day, so they could decode the messages. It is thought that the intelligence gained from Turing's work shortened the Second World War, possibly by years. Solving mysteries, unlocking problems and cracking codes has real life relevance, and mathematicians are still gathering and decoding life-saving intelligence today.

*You can read more about Alan Turing in the article "What Did Turing Do For Us?"*

**How can teachers support their aspiring maths detectives and codebreakers?**

To support pupils and students in solving these problems we have included some useful questions that support their thinking, but without giving them the answers!

What do you notice?

Have you thought about ”¦?

How could you test out your ideas?

What could you do next?

Can you explain your thinking?

But above all, it is important to choose tasks that your students are interested in, that they want to solve and that they are curious about.

*Here is a PDF version of this article.*