# Enigmatic Code

Programming Enigma Puzzles

## Tantalizer 13: Balls

From New Scientist #563, 21st September 1967 [link]

Take a red, a blue and a green bucket. Ask a friend to put into them three red, three blue and three green balls in such a way that:

1. There are three balls in each bucket.
2. There is a blue ball in each bucket.
3. There are no green balls in the green bucket.

Now point to a bucket (without looking inside it) and have him throw you one ball from it at random. Repeat the process until you have collected one red, one blue and one green ball.

What is the smallest number of balls collected in this way which cannot fail to include the selection required?

A variation of this puzzle appears in the book Tantalizers (1970) under the title “Billiard Balls”.

[tantalizer13]

## Tantalizer 12: Aunts

From New Scientist #562, 14th September 1967 [link]

“Be a dear”, said Aunt Agatha, “and write to that nice man about the things”.

“The man who collects beetles about the hymn-books”, replied my aunt without hesitation. “Here’s his address:

Ernest Baggins,
Mallards,
Appleton,
Kent”.

“That doesn’t sound right, dear”, interrupted Aunt Maud. “I’m sure he’s not Baggins. Where’s my book? Yes, here we are:

Ernest Boggins,
Halyards,
Surrey”.

“That’s not what I’ve got”, put in Aunt Jobiska. “I’ve got:

Edward Biggins,
Haystacks,
Cuxham,
Surrey”.

“Not Biggins, Jobiska, Boggins”, this from Aunt Kate.

“Edward Boggins,
Pollards,
Appleton,
Sussex”.

“Stuff!”, said Aunt Tabitha rudely, “He is called Ernest Buggins, poor man, and his address is:

Willows,
Surrey”.

As no Aunt was willing to give way, I had to ring the vicar and he, it turned out, was both deaf and loquacious. However, I got the name and address in the end and found that each aunt had been right in exactly two out of her five particulars.

What is his name and address?

A version of this puzzle appears in the book Tantalizers (1970) under the title “Aunt Maud”.

[tantalizer12]

## Tantalizer 11: Night-watchman

From New Scientist #561, 7th September 1967 [link]

Old Charlie is night-watchman at the Kite Company. His parish consists of 12 buildings and a gatehouse. laid out thus:

His orders are to inspect all 12 buildings during the night. He is to inspect each building the same number of times, beginning with No 1, keeping to the paths shown and ending up finally at the gatehouse. Having inspected a building, he must inspect at least one other (or the gatehouse, which he may inspect as often as he likes) before inspecting that building again. Each stretch of path is 100 yards long, except 1-6 and 1-11, which are 200 yards.

Old Charlie has a conscience and rheumatism so he carries out his orders faithfully but walks not one yard further than he need.

How far must he walk in the night?

This puzzle appears in the book Tantalizers (1970).

[tantalizer11]

## Tantalizer 10: The case of the mangled millionaire

From New Scientist #560, 31st August 1967 [link]

“An inelegant crime”, observed Holmes, surveying the wrecked library. The mangled body of Sir Plutus Gnome sprawled on the rug and beside it lay the hammer and sickle which had produced its present unpleasing condition. Pocketing his magnifying glass, Holmes turned to the five police inspectors.

“Well, gentlemen, what does the evidence tell us of the culprit?”

The first inspector cleared his throat: “We are looking”, he said, “for an unmarried right-handed woman who is shorter than the deceased.”

“No”, said the second, “for an ambidextrous married communist the same height as the deceased.”

“No”, declared the third, “for a married man who is an anti-communist and taller than the deceased.”

“No”, put in the fourth, “for an unmarried, left-handed, female communist.”

“I disagree”, remarked the fifth, “we want a right-handed man, taller than the deceased, who has no feelings about communism either for or against.”

Holmes gave them a glance both penetrating and scornful. “You have done very well, gentlemen” he pronounced. “Each of you is right in exactly two particulars. Now, it is clear that there are only four possible suspects; George Crabtree, the victim’s bachelor nephew, Miss Pringle, his secretary, Henry Hetherington, his accountant, or Henry’s wife, Mary. You will no doubt be able to determine which of the four perpetrated the deed.”

Who mangled the millionaire?

This puzzle appears in the book Tantalizers (1970) under the title “The Mangled Millionaire”.

[tantalizer10]

## Tantalizer 8: The church afloat

From New Scientist #558, 17th August 1967 [link]

When the old destroyer, Fantastic, was turned into a floating missionary chapel, instead of being scrapped, the following worthies were present at her re-launching:

The Bishops of:

Armuth
Bangor
Cone

Sir Desmond Drake
Sir Evelyn Easy
Sir Francis Fish
Sir Gregory Grogg
Sir Harry Hornpipe.

Afterwards they repaired to the wardroom to drink the toast of “The Church Afloat”. It was no thimble-sized toast and presently the eight dignitaries were arm in arm on the deck and singing lustily. Everyone, I regret to report, was wearing someone else’s hat. This is what the bishops sang, each topped with a cockaded nautical tile:

Armuth:
My hat is on the head of a man,
whose hat is on Sir Desmond.
Bangor:
My hat is on the head of a man,
whose hat is on the head of a man,
whose hat is on Sir Evelyn.
Cone:
My hat is on the head of man,
whose hat is on the head of a man,
whose hat is on the head of a man,
whose hat is on Sir Francis.

Sir Harry Hornpipe, resplendent in episcopal mitre, then opened fire:

Hornpipe:
My hat is on the head of a man,
whose hat is on the head of a man,
whose hat is on the head of a man,
whose hat is on the head of a man,
whose hat I’m proudly wearing.

Luckily it started to rain at this point, before anything worse befell. It thus only remained to restore the hats to their rightful owners.

Who was wearing whose?

A variation on this puzzle appears in the book Tantalizers (1970) under the title “The Sailor’s Puzzle”.

[tantalizer8]

## Tantalizer 7b: Three men in a boat

From New Scientist #557, 10th August 1967 [link]

When George, Harris and I go on the river, we take it in turns to row, steer and cook. With George rowing and Harris steering the boat goes slower than with Harris rowing and me steering but faster than with me rowing and George steering.

We have found that the boat’s speed is a simple sum of a rowing element (in knots) and a steering element (in knots) and that each of us makes a measurable contribution at the oars or the helm. George is the best helm or the worst oar or both.

Each of us is the best of us in one department — I mean rowing, steering or cooking — and the worst in another.

Which of us is the best cook?

Both this puzzle and the one published the previous week were Tantalizer 7.

This puzzle appears in the book Tantalizers (1970).

[tantalizer7b] [tantalizer7]

## Tantalizer 7a: Professors in conflict

From New Scientist #556, 3rd August 1967 [link]

The courtyard at Jude’s College is paved with large regular hexagons (as shown).

Professor Xerxes is at present stationed on No. 1 and his old enemy, Professor Youthful, on No. 7. To settle their latest scholars’ feud, they have agreed to a contest under these terms:

1. They will take it in turns to move.
2. Each will move at any turn only to a hexagon he “commands”.
3. Each commands at any time all and only those hexagons which lie in a straight line across any side of the hexagon he is then standing on. (Thus X now commands 2, 3, 4, 12, 11, 10; but not 13, 15, 7).
4. Neither may move to or across any hexagon commanded by the other.
5. Whoever is first unable to move will be deemed the loser.

Xerxes has won the toss. Should he move first? If so, what is his winning strategy? If not, what is his winning strategy after Youthful’s move?

Both this puzzle and the one published the following week were Tantalizer 7.

In the book Tantalizers (1970) a modified version of this puzzle appears as “Battle of Minds”.

[tantalizer7a] [tantalizer7]

## Tantalizer 6: Pets

From New Scientist #555, 27th July 1967 [link]

Five old bachelors live together at Nag’s End, where they are thoroughly overrun by their pets. Each pet is a perfectly normal specimen of its kind. The pets have between them 10 heads and 30 legs. The only quadrupeds are cats or dogs and there are more dogs than cats. The two dog owners keep at least one cat each.

Arthur keeps a budgie but no dogs. Brian owns six legs (including his own two). Charlie and Dan keep the same number of pets and their pets have, collectively, the same number of legs. Edward has had some trouble in training his pets not to follow him upstairs at night.

Who keeps what?

In the book Tantalizers (1970) a reworded version of this puzzle appears.

[tantalizer6]

## Tantalizer 5: Afternoon sun

From New Scientist #554, 20th July 1967 [link]

George and Mabel, who live at one of the 24 towns shown on this map of the island of Angula, have been planning their summer motoring holiday.

George proposed that they should motor along every road shown once and once only. Mabel agreed this was a feasible plan but thought the town they would finish at was a horrible dump. She proposed instead that they should seek the afternoon sun, never motoring north, east or north-east. George agreed and they have also agreed upon their destination. They are now arguing which of the eight possible routes they will take to get there.

Where do they live and where will they be spending their holiday?

In the book Tantalizers (1970) a reworded version of this puzzle appears under the title: “The Beggerman’s puzzle”.

[tantalizer5]

## Tantalizer 4: In the arena

From New Scientist #553, 13th July 1967 [link]

One of the best loved sights of the Roman Arena was a duel to the death between a Gladiator and a Retiarius. The Gladiator, being in armour and carrying a sword, was slow in movement but lethal at close quarters. The Retiarius, having no armour but carrying a net and trident, was most deadly at a distance.

Those who wish to test where the odds lay for themselves will, in these softer days, have to make do with a diagram.

Let us suppose that Gladiator starts at 32 and Retiarius at 1 and that they move in turn. Gladiator moves three circles at each turn and Retiarius four. Both must always move along the lines but can change direction or double back during their move. The duel is won by whoever first lands on top of his opponent at the end of a turn.

Can either player be sure of winning? If so, who?

In the book Tantalizers (1970) a reworded version of this puzzle appears under the title: “The Lion and The Unicorn”.

[tantalizer4]

## Tantalizer 3: Café de Gaulle

From New Scientist #552, 6th July 1967 [link]

My friend Jones has food poisoning, which serves him right. Last night he thought he would impress two girls by taking them to dinner at the newly opened Café de Gaulle. Since the girls have survived the ordeal, we may assume that the trouble lay in a dish which Jones ate and they did not.

Potage Tiede … 1s
Haricots sur Toast … 2s
Coctaile de Crevettes … 3s

Bulle et Couic … 4s
Crapeau dans le Trou … 5s
Trotteurs de Cochon … 6s

Fromage Souriciere … 2s
Morceau Singulier Gallois … 3s
Becasse Ecossaise … 4s

Jones tells me that each of them ate one item from each course and that, not counting tips etc., he paid eight shillings for himself, nine shillings for Polly and 10s for Gladys. No dish eaten by Polly was also eaten by Gladys.

He was in fact able to recall what the girls had eaten and so even though he had forgotten what he ate himself, we could deduce what had poisoned him. The offending dish can, however, be deduced merely from the information given so far plus the information that someone had Becasse Ecossaise.

Which is it?

In the book Tantalizers (1970) a reworded version of this puzzle appears under the title: “Café des Gourmets”.

[tantalizer3]

## Tantalizer 2: A chess puzzle

From New Scientist #551, 29th June 1967 [link]

Frank French, our local chess secretary, was writing out the results of our all-against-all tournament, when in popped Barbara Bocardo, the well-known logician.

“What gives?”, she asked, pouncing on the score sheet, which looked like this:

“The half points are draws”, he explained. “I’ve filled in all there were and next I shall record the 1’s (wins) and 0’s (losses)”.

“Don’t do that. Let me guess. How did you do yourself?”

“Well, I drew in four of the five rounds, as you see. But alas, I finally shared bottom place with Alapin, my opponent in the first round.”

“A lot of draws, surely?”

“Yes. At least one in every round. Each of us drew in at least two consecutive rounds.”

“Did the winners (I see there must have been two of them), meet in the second round?”

“No”.

“Good. It is now possible to deduce whom they played in the last round.”

Can you perform this logical feat?

[tantalizer2]

## Tantalizer 1: Publish or perish

From New Scientist #550, 22nd June 1967 [link]

Kappa, Lambda, Mu and Omicron are at present uneasily seated in the Warden’s study at Jude’s College, awaiting summonses from the committee which will appoint one of them to the vacant Fellowship in Greek Literature. Each is hugging his only published work and each suspects that the post will go to the author of the longest, irrespective of all possible merit.

From their stilted but cunning conversation, the following facts have so far emerged:

Each book has a whole number of pages over 100.

Only Lambda’s book and Mu’s book have the same number of pages.

The total number of pages in all four books is 500.

Mu then asked Omicron whether the number of his (Omicron’s) pages was a perfect square. From Omicron’s answer Mu and Kappa made silent and independent deductions with impeccable logic. Mu deduced that Omicron’s book was the longest. And Kappa, who was not a perfect square, deduced that Omicron’s answer was not the truth.

How many pages are there in each man’s book?

This was the first Tantalizer puzzle published in New Scientist. It was accompanied by the following introduction:

This is the first of a series of logical puzzles compiled by Martin Hollis. No mathematical knowledge is required for their solution. A new puzzle will appear each week, and the answer will be printed in the following week’s issue.

[tantalizer1]