There are a lot of people in the world who hate maths, purely because they think it’s not for them. But, as Cady Heron said in the seminal classic ‘Mean Girls’, “Maths is the same in every country”. It truly is the universal language.
Maths is maths at every level, from complete beginners to PhD-level experts and beyond. It can be incredibly challenging, but it can also be simple and fun.
And sometimes, it’s somewhere in between – a little less than easy, and a little more involved than you think.
That’s the case with this week’s maths puzzle from the Irish Mathematical Trust, which involves a little logic, and a lot of counting.
See if you can figure it out.
The reverse Von Trapp
The Von Trapp children have been called downstairs to meet their new teacher.
The 10 children – there have been three new additions to the family since Captain Von Trapp married Maria – each of a different height, are lined up, left to right, from smallest to tallest. They are told to rearrange themselves, again from left to right, from tallest to smallest.
However, they can only do this by swapping the positions of two children standing next to each other. They can do as many swaps as necessary in order to get into their new formation.
What is the minimum number of swaps needed?
Scroll below the picture to check your answer.
This week’s maths puzzle comes courtesy of Dr Mark Flanagan, associate professor at the School of Electrical, Electronic and Communications Engineering in UCD, who is actively involved in the Irish Mathematical Olympiad and mathematics enrichment classes at UCD.
Solution
The answer is 45.
Let’s call the smallest child 1 and the tallest child 10.
We start with 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, and need to change it to 10, 9, 8, 7, 6, 5, 4, 3, 2, 1.
1 swaps with 2, then 1 swaps with 3, then with 4, and so on until he or she swaps with 10. That’s nine swaps.
After those nine swaps, we end up with 2, 3, 4, 5, 6, 7, 8, 9, 10, 1.
Then 2 swaps with 3, then with 4, then with 5, and so on until her or she swaps with 10 (but not with 1, or we’d just be duplicating the old order).
After those eight swaps, we have 3, 4, 5, 6, 7, 8, 9, 10, 2, 1.
After seven swaps, we have 4, 5, 6, 7, 8, 9, 10, 3, 2, 1.
Continue this pattern until we get to 10, 9, 8, 7, 6, 5, 4, 3, 2, 1.
So, all in all, that’s 9 + 8 + 7 + 6 + 5 + 4 + 3 + 2 + 1 = 45.
Main image via Shutterstock