# Enigmatic Code

Programming Enigma Puzzles

## Puzzle #221: Logical World Cup

From New Scientist #3438, 13th May 2023 [link] [link]

“Drat”, said Ron the reporter. “Now the Logical World Cup is over, the editor wants to know how many games each team won, drew and lost, but all I have are the points totals”.

“Maybe I can help”, said Martha the mathematician. “Show me what you’ve got”.

Ron passed her the sheet of paper he had been glaring at:

“Hm. I presume it was a round robin with three points for a win and one for a draw?”

“But of course”, said Ron.

“Then I can tell you the other columns” said Martha.

Can you?

[puzzle#221]

## Puzzle #206: All square

From New Scientist #3423, 28th January 2023 [link] [link]

“What ho!” boomed Aunt Nicola. I could tell she was about to talk cricket at me. “Have you been following the test match between Pythagorea and Lagrangia?”

“Auntie, you know I prefer Navier-Stokes to Ben Stokes”. “Well”, she said, “you might be interested — there’s maths involved! In their first innings, Lagrangia’s total score was a square number”.

“Innings?” I asked. “It’s the word for a team’s turn to bat. They each have two. In their first, the Pythagoreans also got a square number, but they were more than 300 behind!”

“That sounds insurmountable”. “You might think so”, she said. “Then, when Lagrangia batted again, they added a different square number — less than 50 — so that their lead and overall total were also square numbers”.

“Goodness”. “But the Pythagoreans battled back in their second innings”, she continued, “and the game ended dramatically in a tie”.

I then knew enough to work out the totals of the four innings in order. What were they?

[puzzle#206]

## Puzzle #188: Four forgetful footballers

From New Scientist #3407, 8th October 2022 [link] [link]

“I guess we had a football tournament yesterday”, said Clara, the Cleverton goalkeeper, noticing the trophy for the Friendly International Tournament for the Brainy but Absent-Minded on the table.

“I wish I could remember”, said Sima, the Smarta Prague centre-back. “I presume it was the usual 3-points-for-a-win affair, with ties settled using goal difference”.

Astutegart’s star striker, Astrid, agreed. “I remember…” (she stopped to count) “… four teams all played each other! And in each game, there were exactly three goals”.

“I remember that we all scored a different total number of goals”, said Inge, Interlecht’s winger. “And each team scored a different number of goals in each of our games”.

“I remember”, said Clara, “that we let in more goals than anyone else”.

“I scored three goals against you, Clara”, said Sima.

“And Inge scored three against us”, said Astrid.

Inge thought for a moment. “Then I can work out who won the tournament”.

Who did win?

[puzzle#188]

## Puzzle #128: Tournament headache

From New Scientist #3349, 28th August 2021 [link] [link]

Four hungover footballing mathematicians groaned in unison. “Anyone remember who won yesterday’s tournament between our four teams?” asked Ranko, the Red Star Belgradient goalkeeper. Ignacio, the Integer Milan striker, raised his hand feebly. “I remember that we each played each other once. Three points for a win. One for a draw. And all of the scorelines were different”.

Tom, the Tottingup Hotspur defender, opened one eye. “Are 1-0 and 0-1 different or the same?” “They’re the same, obviously!” said Patrick, of PSV Eigenvector, adding: “I remember that every team scored a different number of goals in each of their games”.

“But never more than two!” said Ranko. “And I know my team didn’t concede a goal”. Patrick pulled a silver medal out of his pocket. “And we must have finished second”, he deduced.

“I know which game ended 2-2!” said all four at once.

Which was it?

[puzzle#128]

## Puzzle #50: Crossing the river

From New Scientist #3273, 14th March 2020 [link] [link]

Petal is on her way to a country fair, to sell some vintage kitchenware belonging to her good friend Gretel. As she walks along the River Biddle admiring the view, Petal trips on a pair of oars left carelessly on the bank. A valuable wrought-iron kettle flies out of her hand and lands on one of the river’s many marshy islands.

From the river bank to the island is 3 metres directly across, and though the oars are sturdy enough to walk on, they are just short of reaching over the water.

How can Petal reach reach the island with the paddles and save Gretel’s metal kettle from its muddy peril?

[puzzle#50]