Enigmatic Code

Programming Enigma Puzzles

Tag Archives: by: Keith Austin

Enigma 554: Pure magic

From New Scientist #1707, 10th March 1990 [link]

I found myself on the stage if the Southwich Pavilion, helping the Great Marvello with his act. Marvello pointed to an endless row of boxes stretching off into the wings. The boxes had numbers on their lids, 1, 2, 3, … Marvello explained that each box contained a number of coins, at least one coin in each box.

As I stood in the centre of the stage, Marvello asked me to choose a number and I said 15. He told me to multiply my number by 6, and I gave him the answer, 90. He then told me to look in the box with 15 on its lid, count the coins in it and write the number of coins on the blackboard on the stage.

When I had done that, Marvello told me to open the box which had the number on the blackboard on its lid. I then had to count the number of coins in the box and subtract the number from the 90 I had obtained earlier. When I announced my answer to the audience, the great Marvello pointed with a flourish to the blackboard, for my answer was exactly the same as the number on the board. The audience applauded wildly.

After the show, Marvello explained that whatever number I had chosen he would have given precisely the same instructions, including multiplying by 6, and the trick would have worked out in the same way.

How many coins were in the box with the number 1990 on its lid?

[enigma554]

Enigma 955: Puzzle yourself

From New Scientist #2110, 29th November 1997

You have to construct a puzzle by putting the numbers 2, 3, 5, 7, 11, 13 and 17 in some order into the boxes in the following framework:

I have a number X which is one of:

2730, 4290, 5610, 6006, 6630, 10010, 13090, 14586, 15015, 15470, 24310, 34034, 36465, 39270, 46410, 255255, 510510.

Also X is divisible by ⬜, ⬜, ⬜, ⬜, ⬜ and ⬜.

Is X divisible by ⬜?

Your puzzle should give a unique answer and be such that all the divisibility clues in it are needed to obtain the answer.

Which number should you put in the last box of the framework?

[enigma955]

Enigma 550: Do your level best

From New Scientist #1703, 10th February 1990 [link]

Bern, Cara and Loren are climbing in the Hillymayas and have decided to tackle Mount Veryrest which is 700 metres high. There are three different approaches and they each take a different one. Bern’s approach is shown in the diagram.

All slopes in the Hillymayas have the same steepness — 1 up or down for 1 across; all climbers go at the same pace — 100 metres up or down in each hour. Thus, Bern could reach the top in 13 hours.

Bern’s approach is described as: up 5, down 3, up 5.
Cara’s approach is: up 3, down 2, up 4, down 1, up 3.
Loren’s approach is: up 5, down 2, up 3, down 6, up 7.

The three decide that, to be fair, they will climb so that, at each point in time, all three are at the same height. This will involve some retracing of steps. Given that condition, they try to reach the top as soon as they can.

How may hours does it take them to reach the top?

[enigma550]

Enigma 961: Alphabetical hockey

From New Scientist #2117, 10th January 1998 [link]

There are 20 teams in our local hockey league, with the quaint 1-letter names, A, B, C, D, E, …, S, T. Last season, every team played every other team exactly once and there were no draws. Looking at the last season’s results, I noticed that if I choose any match then the winning team beat every team that occurs later in the alphabet than the losing team.

(1) Can you also say for certain that if I choose any match then the losing team lost to every team that occurs earlier in the alphabet than the winning team?

(2) Can you say for certain who won the match K vs O? If you can, name the winner.

I also noticed that at least 10 of the matches were won by the team that occurs later in the alphabet.

(3) Can you say for certain who won the match L vs M? If you can, name the winner.

[enigma961]

Enigma 546: Concede or score

From New Scientist #1699, 13th January 1990 [link]

The Midchester football league contains four teams: Albion, Town, United and Victoria. In the season that has just finished, each team played every other team once, and the matches were played on three consecutive Saturdays. For each team, the Guardian Chronicle has printed that team’s performance through the season in the form of a list of all the goals scored in that team’s matches in chronological order. The list for a team states whether each goal was conceded, C, or scored, S, by that team. The list does not indicate where one match ends and the next begins.

Albion – C S C C S C C C S
Town – S S S S S C C S S
United – S C C S C C
Victoria – C C C S S S S C

Give the scores in Albion’s three matches in chronological order.

[enigma546]

Enigma 544b: Little puzzlers

From New Scientist #1696, 23rd December 1989 [link]

Amy, Beth, Jo and Meg decided to give each other pots of marmee-lade for Christmas. Each girl made a number of pots and then divided her pots into three piles, which were not necessarily equal; then she wrapped up each pile, labelled each parcel, and put them under the Christmas tree. The total number of pots involved was between 50 and 100.

We will let the letters A, B, C, …, I stand for the digits 1, 2, 3, …, 9 in some order. Amy gave D/F of her pots to Jo, and C/B to Meg. Beth gave H/G of her pots to Amy, H/A to Jo, and D/G to Meg. Jo gave F/G of her pots to Amy. Meg gave A/B of her pots to Beth, and D/H to Jo.

On Christmas day, each girl opened the three parcels she had received. Amy received H/E of her pots from Beth, and F/E from Jo. Jo received D/I of her pots from Amy, D/H from Beth and D/A from Meg.

Note that all the fractions were in reduced form before letters were substituted (1/2 and 2/3 are in reduced form, whereas 4/8 and 6/9 are not).

What was the total number of pots that were given?

News

This puzzle completes the archive of Enigma puzzles from 1989. There is now a complete archive of New Scientist puzzles from July 1975 to December 1989, and from February 1998 to December 2013, a total of 1553 puzzles. There are 423 Enigma puzzles remaining to post.

[enigma544b] [enigma544]

Enigma 543: Spires point the way

From New Scientist #1695, 16th December 1989 [link]

The quiet town of Spirechester is divided into nine square parishes as shown on the map. Each parish church has its spire precisely at the centre of the parish, and these are marked by crosses on the map.

Enigma 543

The churches are named after St Agnes, St Brigid, St Cecilia, St Donwen, St Etheldreda, St Felicity, St Genevieve, St Helen and St Isabel. Each spire is topped by a weather vane which has, instead of a cock, the initial letter of its saint’s name.

Recently I walked in the meadows which surround the town and took a number of photos from different positions. Fortunately, no spire was ever hidden by another spire and the wind was such that the weather vane letters were clearly visible. However, I was not sufficiently distant from the town to capture all nine spires and, in fact, each photo contains just five spires. The orders of the spires of the photos, reading from left to right, were GEIAC, EACHD, EACDH, AECHD, IFCGB.

Starting with A (for St Agnes) list the eight churches in clockwise order around the outside of the square.

[enigma543]

Enigma 970: From line to line

From New Scientist #2125, 14th March 1998 [link]

Take a large sheet of lined paper. On line 1 write any number between 0 and 100 (but not necessarily a whole number). In turn, write a number on each of the lines, 2, 3, 4, …, 100, according to the following rule:

Suppose you have just written a number X on a line. If X is less than 50 then write 40 plus half of X on the next line, otherwise write 93 minus half of X.

(A) Can I say now, before you write your number on the 1st line, what the nearest whole number to the number you write on the 100th line will be? If yes, then what is that nearest whole number?

Take a second sheet of lined paper and repeat the above, except that the rule if X is less than 50 is changed; now write 20 plus half of X on the next line.

(B) My question now is as in question A.

Now take a third sheet of lined paper and repeat the procedure, except that the rule becomes the following. If X is less than 50 then write 40 plus half of X, otherwise, write 15 plus half of X.

(C) Once again, my question is as in question A.

[enigma970]

Enigma 538: Rule of the road

From New Scientist #1690, 11th November 1989 [link]

I recently visited Ruralania with its five towns, Arable, Bridle, Cowslip, Dairy, Ewe, joined by one-way roads labelled high or low, as in the map:

Enigma 538

The Ruralanian road system is very simple; if a driver is at one of the five towns then the systems says whether he or she is to leave that town by the high road, by the low road, or to stop in that town.

The system is determined by the fact that it must be possible to make a Grand Tour by starting at a certain town and driving round visiting all the towns and stopping at the final town, while always obeying the single Rule (X):

Take the high road if taking the low road and then obeying Rule (X) again, results in your car next being at A or E. Otherwise, take the low road if taking the high road and then obeying Rule (X) again, results in your car next being at C. Otherwise, stop in the town where you are.

What is the Grand Tour? (List the towns in order).

[enigma538]

Enigma 973: Choss, anyone?

From New Scientist #2128, 4th April 1998 [link]

The game of choss is played by two players, Black and White, on a board of 6 × 6 squares. Each player has a number of pieces which he or she moves one square horizontally or vertically. The players take it in turns to move one of their own pieces. A piece cannot move into a square already occupied by a piece of the same colour. If a piece moves into a square occupied by a piece of the opposite colour, that the other piece is captured and removed from the board. One White piece is larger than the other pieces and is called the Target. Black wins by taking the Target.

The layout of the board is as shown and it is Black’s move. She can in fact definitely win in three or fewer moves.

1. What should the first of these moves be?

That was the Enigma that I intended to set, but the editor thought it was too easy. He suggested that I change the board layout above by moving the Target to some other unoccupied square where it cannot be immediately taken by Black, but so that from the new layout Black can again definitely win in three or fewer moves. He then suggested that I asked Question 1 about this new layout.

Of course I shall have to choose the new position of the Target so that Question 1 has a unique answer.

2. To which position should I move the Target?

[enigma973]

Enigma 975: Ant goes for a walk

From New Scientist #2130, 18th April 1998 [link]

Imagine an 8 × 8 chess board and imagine that in each square of the board there is written one of the following four instructions:

Turn right;
Turn left;
Go straight ahead;
Go back.

An ant is placed at the centre of the bottom left corner square. She walks, parallel to the bottom edge of the board, until she reaches the centre of the next square. She reads the instruction in the square she is in and sets off walking in the direction specified by that instruction. She walks in a straight line until she reaches the centre of a square or until she walks off the board; in the latter case, her walk stops. She continues her walk in this way, from square to square, obeying the instruction each time. She walks until she reaches the top right corner square, or she walks off the board; when either happens, her walk stops. In the former case it is called a successful walk.

Answer each of the following questions, “Yes” or “No”.

1. Is it possible to find a successful walk in which the ant repeats some part of her walk?

2. Is it possible to find a walk in which the ant does not repeat the first part of her walk but does repeat some part of her walk?

3. Is it possible to find a successful walk in which the ant visits the top left-hand corner square of the board more than once?

4. Suppose now that the board is 4 × 4. Is is possible to write an instruction in each square, using each of the four different instructions four times, so that the ant’s walk visits every square of the board at least once?

[enigma975]

Enigma 534: Under and over

From New Scientist #1686, 14th October 1989 [link]

The important C.A.R. Rally has just been held at Bun’s Hutch, where the track is as in the map.

Enigma 534

There were 12 cars in the rally, numbered 1 to 12. For the start at 10:00, the cars took up the 12 lettered positions on the map, one car to each position. At 10:01 the cars all reached their first bridge, going under or over; at 10:02 the cars all reached their second bridge.

I had taken a photo at 10:01 and also at 10:02. Each photo showed all the numbers of the cars and so each bridge showed a fraction with one number over another. On one photo the fractions worked out to be 1/2, 2/3, 2/3, 2 1/3, 4, 5 1/2, and on the other 2, 2, 2, 3, 5 1/2, 7, but I forget which photo was which.

Which cars started at each of the 12 letters?

[enigma534]

Enigma 977: Walk and drive

From New Scientist #2132, 2nd May 1998 [link]

Anne, Barbara and Christine walk at 4 mph and drive at 48 mph. They have a journey of 24 miles to do but their car only takes 2 people. So Anne sets off walking, while Barbara drives so far with Christine, who then gets out and walks the rest of the journey. Barbara drives back until she meets Anne, picks her up and the drive the rest of the journey. They choose Christine’s dropping place so as to minimise the time taken by the last person to arrive.

1. How many minutes did the last person take for the journey?

Donald, Eric and Frank have to make a journey of 265 miles. They each walk at a speed which is a whole number of mph and the speed of their 2-seater car is a whole number times their walking speed and is less than 50 mph. They use the same plan as the ladies. The last person to arrive takes an odd number of hours for the journey.

2. How many hours did the last person take for the journey?

[enigma977]

Enigma 530: Sudden death

From New Scientist #1682, 16th September 1989 [link]

There were eight players in the Greenchester Knock-Out Golf Championship. Unfortunately, due to rain, the whole competition had to be played on Saturday afternoon, and so it was decided to play the four first-round matches, the two semifinals and the final as sudden-death matches.

Thus in each match the two players played one hole and, if the scores were different, then the lower was the winner of that match. If the scores were equal then the played another hole with the same procedure applying, and so on, until the winner of that match was found.

After the competition the organiser listed each player’s scores for the holes (s)he had played, in order. Unfortunately he did not indicate the number of holes played in each round, but ran the scores together in a single list, as follows:

Anne: 3,3
Bern: 4,2,3,4
Chris: 4,2,3,3,3,3,3,3,2
Donald: 3,2,3,3,3
Eric: 4
Frances: 4,2,3,3,4
Grace: 3,2,3,4
Harriet: 4,2,3,3,2,4

Who beat whom in the semifinals?

[enigma530]

Enigma 980: Near and fair

From New Scientist #2135, 23rd May 1998 [link]

Mary stood at the side of a large pile of turnips, which she was to distribute evenly between the needy people of the area, who were standing in front of her. The rule was that if the turnips did not divide evenly between the people that Mary should go to the nearest sensible division. (If necessary, extra turnips could be added or spare turnips disposed of). Quickly, she divided the number of turnips by the number of people and found the answer was between 99 and 100, and nearer to 99. As she knew that 100 turnips would be better for people’s health she decided to carry out the division in a special way.

She announced: “Suppose everyone get 99 turnips. I have the divided the number of turnips by 99”, and she gave the answer to lots of decimal places. “Now, suppose everyone gets 100 turnips. I have divided the number of turnips by 100”, and she again gave the answer.

“If we look at our two answers, then we find that the one that is nearer to the actual number of people is when everyone gets 100 turnips. So, by the rule, that is what everyone will get”.

The distribution did not take long as there were fewer than twenty thousand turnips in the pile.

How many people were there to receive turnips, and how many turnips were there in the pile?

[enigma980]

Enigma 526: Ewe to move

From New Scientist #1678, 19th August 1989 [link] [link]

Each of the four fields at Sunny Meadows Farm contains some sheep and some cows. On the gate of each field is hung a sign saying what fraction of the animals in that field are sheep. The signs are 1/2, 1/3, 2/3, 1/4.

Farmer Gillian explained that if she exchanged the signs on [any] two of the fields then, by simply moving some sheep from one of the two fields to the other, she could return to a situation where each sign again correctly indicated the fraction of the animals that were sheep in that field.

As I walked round I noticed that the total number of animals on the farm was between 300 and 350.

How many sheep, and how many cows, were on the farm?

I added the “any” in square brackets, as without it there are many solutions to the puzzle.

[enigma526]

Enigma 984: Answers on the back

From New Scientist #2139, 20th June 1998 [link]

I have 8 cards and each card has a whole number on the back. Not all the 8 numbers are the same. On the front of each card there is a true statement about the number on the back of the car. The eight statements are as follows:

“The number on the reverse of this card is…
… 2 plus the number of cards with an even number on them;
… the total of the 8 numbers, divided by 5;
… the number of cards with a prime on them;
… the number of cards with a number larger than 3 on them;
… the difference between the largest number on the cards and the second largest number on the cards;
… the difference between the smallest number on the cards and the second smallest number on the cards;
… the number of cards that have the largest number on them;
… the difference between the number of cards that have the smallest number on them and the number of cards that have the second smallest number on them.”

When a statement refers to a number on a card it means the number on the back of the card. And an extra clue, which you do not actually need, is that if card A has a higher number on it than card B then card A comes before card B in the above list of statements.

What are the 8 numbers on the cards? Give them in descending order.

[enigma984]

Enigma 988: Cards high and low

From New Scientist #2143, 18th July 1998 [link]

Benjamin and Matthew have a new card game involving 50 cards numbered 1 to 50. They deal out the cards and Matthew finds he has 1 to 16 and 36 to 44. The game consists of 25 rounds. In each round one player places one of his cards face-up on the table and then the other places one of his face-up on the table. The one who has played the higher card wins that round; the two cards on the table are discarded. For the first round the players toss [a coin] to see who goes first, but after that, each round is begun by the winner of the previous round.

Benjamin and Matthew are both experts at the game and each plays so as to win as many rounds as possible.

(1) How many rounds does Benjamin win?
(2) For the next game Matthew has 1 to 7 and 16 to 33. How many rounds does Benjamin win?
(3) For the final game Matthew has 1 to 8 and 30 to 46. How many rounds does Benjamin win?

[enigma988]

Enigma 521: Changing truths

From New Scientist #1673, 15th July 1989 [link]

As I made my way through the jungle with my truthful guide Lamoura, we came upon a clearing, at the centre of which was a large stone. On the stone were carved the following four sentences:

(A) B is true today and C and D are false today, and D is moon.
(B) An even number of A, B, C, D are false today or C is moon.
(C) B is true today and A and D are false today, and B is moon.
(D) B is true today and A and C are false today, and A is moon.

Lamoura explained that beginning on the morrow and running for the next few days was the festival of the Green Moon. So we decided to camp there until the festival was over.

Lamoura told me that on each day of the festival, each of the four sentences is true or false; she also explained that to say that a sentence is moon means that on at least one day of the festival the sentence is true and on at lease one day it is false.

As each day of the festival dawned, a local native gave me a piece of paper stating which sentences were true that day and which were false. I kept these papers and at the end of the festival, I was able to check that what was written on them agreed with what Lamoura had told me. I also noticed that no two papers said the same thing.

How many days did the festival last, which sentence or sentences were true every day, which were false every day, and which were moon?

[enigma521]

Enigma 517: Walk in the dark

From New Scientist #1669, 17th June 1989 [link]

Out there, somewhere in the night, is Elk Elloy, gunning for me. My only hope is to stay in the dark.

Stretching ahead of me is the Boulevard, all 3686.3 yards of it. If I can make the other end of it then I’ll be safe. But the whole length of the Boulevard is covered with neon strip lights. One hundred and ninety-three of them, each 19.1 yards long, set out end-to-end. They flash on and off steadily through the night. There go the 1st, 3rd, 5th, 7th, …, 193rd. They’re on for just an instant. Now there is a 12-second pause and then on come the 2nd, 4th, 6th, …, 192nd, for just an instant. Then another 12-second pause and we begin all over again with the odd numbered strips.

Fortunately, each strip only lights the ground directly below it, so there is a chance I can walk along the Boulevard and avoid ever being under a strip when it comes on.

There are just two catches. First, I must walk at a constant speed which is a whole number of yards per minute, otherwise I will arouse the suspicion of Patrolman Nulty who covers the Boulevard. Secondly, I cannot walk at more than 170 yards per minute.

What speed should I walk at, in yards per minute?

[enigma517]

%d bloggers like this: