# Enigmatic Code

Programming Enigma Puzzles

## Tantalizer 409: Fe, Fi, Fo, Fum

From New Scientist #959, 24th July 1975 [link]

On the Mount of Mystery dwell those ostraglobulous giants Og, Gog and Magog. They can smell the blood of any Englishman within 400 leagues. So they spotted John Bull as soon as he came within range. But they let him get as far as the bar at the Pig and Whistle, while they finished their elevenses.

Then away they went. Og strode off in his five league boots, Gog in his six league boots and Magog in his seven league boots. Progress was speedy and John got a shock when he chanced to look though the bottom of his mug ten minutes later. Og was a mere nine leagues away, Gog a mere seven and Magog a mere ten.

Without going into gory details, can you say how far it is from the Mount to the Pig and Whistle?

[tantalizer409]

## Tantalizer 410: The Clans together

From New Scientist #960, 31st July 1975 [link]

It was a fearsome Hogmany, attended by 11 McSporrans, 11 McTavishes, 11 Mackinnons and 11 MacHinerys. Mind you, that makes it sound worse than it was. The total number present was in fact, smaller, each person being a member of exactly two of the clans.

Especially numerous were those who belonged jointly to the McSporrans and McTavishes. There was no other group which outnumbered them and they outnumbered the McSporran-Mackinnons by precisely two to one.

How many of the company were simultaneously Mackinnons and MacHinerys?

The original puzzle spells “Mackinnon” differently each time it is used.

[tantalizer410]

## Tantalizer 411: Diplomatic niceties

From New Scientist #961, 7th August 1975 [link]

When H.M.G.’s five top ambassadors all fell under the same bus, there was an immense fuss about their replacements. The corridors of power hummed with insinuations, until at last a list of five names and a set of conditional agreements was achieved. The latter read:

1. If Sir Basil Brace does not get Paris, Sir Emlyn Entry shall have Bonn or Rome.
2. If neither Sir Ambrose Amble nor Sir Donald Duck gets Washington, Sir Crispin Carruthers shall have Paris.
3. If Sir Ambrose Amble does not get Bonn, Sir Crispin Carruthers or Sir Emlyn Entry shall have Paris.
4. If Sir Donald Duck does not get Rome, then, if Sir Ambrose Amble does not get Paris, Sir Emlyn Entry shall have Moscow.
5. If Sir Ambrose Amble does not get Washington, then, if Sir Donald Duck does not get Moscow, Sir Crispin Carruthers shall have Bonn.

Having been duly warned that “if x then y” does not mean or imply “if not x then not y”, can you assign the top chaps to the right places?

[tantalizer411]

## Tantalizer 412: Consider your verdict

From New Scientist #962, 14th August 1975 [link]

While waiting for the judge to settle his wig, sharpen his quill and pump up his cushion, each member of the jury wondered how the 11 others would vote when it came to the point. Here are their predictions in alphabetical order:

Juror A thought all the others would favour acquittal.

Juror B thought all the others would be for convicting.

Juror C thought exactly one of the others would want to convict.

Juror D thought exactly one of the others would want to acquit.

Juror E thought exactly 10 of the others would want to convict.

Juror F thought exactly 3 of the others would want to acquit.

Juror G thought exactly 8 of the others would want to convict.

Juror H thought exactly 7 of the others would want to acquit.

Juror I thought exactly 4 of the others would want to convict.

Juror J thought exactly 8 of the others would want to convict.

Juror K thought exactly 3 of the others would want to acquit.

Juror L thought exactly 9 of the others would want to convict.

In the event all those whose predictions were incorrect voted for one verdict, whereas those (if any) whose predictions were correct voted for the other.

Which jurors favoured acquittal?

A correction (applied to the text above) was published with Tantalizer 416.

[tantalizer412]

## Tantalizer 413: Sports day

From New Scientist #963, 21st August 1975 [link]

There were three events after tea and the headmaster appointed Mr Prendergast as bookmaker. After some thought, Prendy produced quite a pretty plan. For a £1 stake you specified the three winners in the order of events (javelin, long jump, hurdles). If you were wholly right, you collected £10. If you got two events right you collected £4. If you were right about the javelin only, you collected £2. Otherwise you lost.

But Prendy had reckoned without Captain Grimes and Dr Fagan (the headmaster), who nobbled all entrants except Clutterbuck, Oglivie and Tangent. Grimes then staked £6 on bets of: CTT; TCC; OTT; COC; OTO; CCO. He made a profit of £4.

The headmaster also staked £6 and naturally did a little better, with a profit of £6 from his bets of: CCT; TOT; OTC; TOC; CTO; OCO.

Which boy won each of the events?

Corrections (applied to the text above) were published along with Tantalizer 414 and Tantalizer 416.

This issue of New Scientist also contains an article about a computer program for solving Tantalizer puzzles using natural language [link].

[tantalizer413]

## Tantalizer 414: Three men in a catastrophe

From New Scientist #964, 28th August 1975 [link]

George, Harris and I once decided to acquire a cat apiece. Dear little furry things they were, little bundles of innocence. Or so we thought before we got them home.

But original sin will out and we soon found that none of them was in the least well behaved. George’s was better behaved than the Siamese. The Persian was better behaved than Bubbles. Harris’s was better behaved than Fluff. The Tabby was not worse behaved than the Persian.

All in all we weren’t sorry when Montmorency, the dog, took a hand [paw?] and sent them caterwauling. He took a particularly satisfying bite out of Pollyanna. Whose cat was she?

[tantalizer414]

## Tantalizer 415: Dizzy spell

From New Scientist #965, 4th September 1975 [link]

Here is a simple prescription for vertigo. Draw a 4×4 grid (16 cells in a 4×4 array). Write a V in the bottom left corner, an E in each of the two adjacent cells, and R in each of the three empty cells adjacent to an E, a T in each of the four empty cells adjacent to an R, an I in each of the three empty calls adjacent to a T, a G in each of the two empty cells adjacent to an I and an O in the top right corner.

To induce mild vertigo, work out how many ways there are of spelling VERTIGO, starting the the bottom left corner and ending at the top right, as if you were an ant taking exercise. The answer is 20. Feeling better?

Tougher exercise can induce schizophrenia. So start again with a 7×7 grid and repeat the prescription with SCHIZOPHRENIA.

How many ant-like ways are there of spelling that?

[tantalizer415]

## Tantalizer 416: Prior arrangements

From New Scientist #966, 11th September 1975 [link]

“This being Wakes Week”, announced the Prior, “I have devised a bit of fun. I shall now paint a red or a blue blob on the pate of each of you for each of the others to see. There will be more red than blue but there will be at least one blue. Each of you is, of course, a perfect logician, and each of you must try to discover your own colour by logic alone. You follow me?”

Eleven tonsured heads nodded gravely and the Prior continued: “On the first stroke of the Compline bell anyone who has already discovered his colour shall leap loudly into the middle of the cloisters for the others to see”. The brothers dispersed and on the first stroke of the bell no one moved a muscle. But when it sounded 24 hours later, an odd number of monks sprang out and cavorted in the cloisters.

How many pates had the Prior painted blue?

[tantalizer416]

## Tantalizer 417: King Kong

From New Scientist #967, 18th September 1975 [link]

This ancient Ethiopian game is a sort of Rugby football played with a melon. There are just two ways of scoring. By tossing the melon over a branch of your opponent’s Haha tree you score a King, worth five points. By passing it through his ring of plaited Oompah grass you score a Kong, worth three points. If the match is drawn, each party collects an ox. Otherwise the winner gets two oxen.

Each of the four regions sends its champion to the annual Tourney of the Winds, where each plays a single against each of the others. This year 44 points were scored in total, of which North gained 10, East 15 and South 11. 13 points were scored against North and 9 against East. South drew at least two matches and no two teams received the same number of oxen.

What Kings and Kongs were scored in the match between North and West?

[tantalizer417]

## Tantalizer 418: Life in the old dogs

From New Scientist #968, 25th September 1975 [link]

Once a year one-legged parrot-fanciers gather from all over Britain to take part in the Long John Silver Memorial Chess Tournament. Each entrant plays one game against each other, scoring 2 points for each win, 1 for each draw and 0 for each loss. The victor gets 16 men on a dead man’s chess board (yo ho ho) and a bottle of rum.

This year a record 1081 games were played. Each entrant totalled a different number of points, finishing ahead of everyone younger than himself. No one totalled an odd number of points. No two players were the same age.

George was the youngest player to win a game with the King’s Gambit and Henry the oldest to lose one with the Slav defence. All those who played the Slav defence finished ahead of all who played the King’s Gambit.

What was the result of the game between George and Henry?

[tantalizer418]

## Tantalizer 419: Wollycobblestones

From New Scientist #969, 2nd October 1975 [link]

There is a fascinating gallstone museum in the Yorkshire town of Wollycobble and folks come from miles around. But it costs a bit of brass to run and there has long been an admission charge. On the principle that the older you are the more interesting other folk’s insides become, the rate is traditionally 1p per year of age. Thus a 10 year old pays 10p, a chap aged 38 pays 38p and so on.

But prices have just had to go up. Yet tradition is sacred. So, craftily, the rate of 1p per year of age remains but now there are only 5p and 7p tickets. As a result the 10 year old still pays 10p (= 5p + 5p) and a 38 year old 38p (= 7p + 7p + 7p + 7p + 5p + 5p); but a 3 year old now pays 5p and an 18 year old 19p (= 7p + 7p + 5p).

The Bundle family makes an annual pilgrimage and, having this year 50 members of all different ages from 1 to 50, arrived expecting to pay £12.75.

At least how much extra did the wily curators extract from them by insisting on the new ticket system?

[tantalizer419]

## Tantalizer 420: Box and Cox

From New Scientist #970, 9th October 1975 [link]

At noon precisely Box left the Lion at Hogpen and set off on foot for the Plough at Inkwell. At noon precisely Cox left the Plough and set off by bicycle for the Lion. When they met Box had covered 4 miles. After 10 minutes’ chat Cox gave Box the bike and walked on to the Lion, where he sank a pint in 3 minutes and set off again for the Plough. Box meanwhile cycled on to the Plough as soon as Cox left him, lowered a pint in 3 minutes and cycled off again towards the Lion.

They met this time 7 miles from the Plough and discussed wurzels for 10 minutes. then Box relinquished the bike and walked on to the Lion and Cox cycled on to the Plough. Pints were sunk in two minutes this time and off our heroes went again with Cox still mounted and Box afoot. They collided two miles from the Lion.

Let Box walk at p mph and cycle at 9 mph. Let Cox walk at r mph and cycle at s mph. Let the road be ever so wiggly.

How many miles is a single journey along it?

[tantalizer420]

## Tantalizer 421: Present time

From New Scientist #971, 16th October 1975 [link]

“I say”, said young Tommy on Christmas morning, when we had each seen our own presents but no one else’s, “here is a poser based on the tea-strainer, bath hat, bath soap and gloves I gave Jane, Kate, Lucy and Maud. I shall now put three questions and each of the girls must give at least two true answers out of the three”.

He first asked, “Did I give you the tea-strainer?” and got the answers: Yes, Yes, No, No. Then he asked: “Did I give you something for the bath?”, getting the answers: Yes, No, Yes, No. The he asked: “Did I give you something to wear?”, getting the answers: No, Yes, Yes, Yes. (Answers are in alphabetical order of girls).

“Now”, he said to the rest of us, “I can tell you that exactly one girl is in a position to deduce what each other girl got. Can you tell me what each girl did get?”

Due to a typo in New Scientist this puzzle was published as Tantalizer No 42.

[tantalizer421]

## Tantalizer 422: Holy matrimony

From New Scientist #972, 23rd October 1975 [link]

When the five ministers at St. Saviour’s all got divorced, it was a relief. When all announced a remarriage, it was a surprise. When the brides were revealed to be the five ex-wives, it was a sensation. Still, the priggish Dinah was not the first to remarry and there were no direct swaps, so I daresay the decencies were preserved.

The weddings were held on successive Saturdays. Peter’s took place earlier than Anne’s and later than Quentin’s. Barbara’s was later than Tristram’s and earlier than Celia’s.

Peter married Simon’s ex-wife. Barbara got hitched to the man whose former wife married Emily’s ex-husband. Quentin paired up with the lady whose former husband married Dinah. Ronald was spliced with the lady whose ex-husband married Celia.

Who, pray, is now married to whom?

[tantalizer422]

## Tantalizer 423a: Humbugs

From New Scientist #973, 30th October 1975 [link]

Aunt Edith sweetened her departure by giving each of our five children a bag containing 10 fat stripey humbugs. She made them all promise to hold off till after breakfast but Barbara is as persuasive as she is unprincipled and she and the others all arrived at the table chewing.

Taking stock over the porridge, I found that half the surviving humbugs belonged to children with an even number [remaining] and that the twins still had 14 between them. Only Anne had more than one less than average, but even she still had more than one humbug. Charles still had less than William but more than Pat. The girls still had exactly 10 between them.

How many did each child have left?

Note: Both this puzzle and the following puzzle were labelled Tantalizer No 423 when published in New Scientist. So I’ve labelled this one 423a to distinguish them.

[tantalizer423a] [tantalizer423]

## Tantalizer 423b: Body count

From New Scientist #974, 6th November 1975 [link]

The first motion before the conference of Family Doctors was that Miss Emily Scroggins be invited to deliver a lecture on the female epidermis. The Chairman rapped importantly with his gavel:

“I shall put the motion without debate. Those in favour? … Those against? … I declare the motion lost by a majority exactly equal to one quarter of the number voting in favour. Good gracious! Well there’s no need for anyone to be disappointed. Those who wish can view Miss Scroggins tonight at the Golden Tuffet, where she strips to music under the name of Gloria Gunn. What’s that you say, Sir? You would like to change your vote? I daresay you are not alone in that. How many of those previously opposed are now in favour? Twelve, I see. And those previously for but now against? None, I see. This more like it. I declare the motion carried by one vote”.

How many persons were present and voting?

This puzzle and the previous puzzle were both labelled Tantalizer No 423, when originally published in New Scientist. So I’ve labelled this one as 423b to distinguish them.

[tantalizer423b] [tantalizer423]

## Tantalizer 424: Directory enquiry

From New Scientist #975, 13th November 1975 [link]

Mr Meek is pleased with his new phone number, because it has four digits, the middle two of which are identical. “Like my name”, he explains. The repeated digit is also the first digit of Mr Humble’s new four digit number. Moreover Mr Meeks first digit is the same as the first digit of Mr Lowly’s new four digit number.

If you interchange the first and last digits of Mr Lowly’s number, you get Mr Humble’s. If you subtract Mr Lowly’s number from Mr Humble’s, you get Mr Meek’s.

So what is Mr Meek’s new number?

[tantalizer424]

## Tantalizer 425: Beauty contest

From New Scientist #976, 20th November 1975 [link]

To enliven the tedium of the beauty contest, the judges started by each sealing his guess for the first four places, before even seeing the girls. Afterwards they opened the envelopes and scored one point for each girl mentioned who finished in the final four and a further nine points for each girl given her correct placing.

Winner, was trendy Bishop Bonhomie with 21 points for 1st. Miss Paignton, 2nd. Miss Lincoln, 3rd. Miss Oban, 4th. Miss Wigan. Next came Peter Pint the telepoet with 12 points for 1st. Miss Oban, 2nd. Miss Northampton, 3rd. Miss Formby, 4th. Miss Paignton. A mere 3 points were garnered by Chico the Chiropractor with 1st. Miss Wigan, 2nd. Miss Oban, 3rd. Miss Lincoln, 4th. Miss Formby. The booby prize went to Dan Dare the famous celebrity, who netted 2 points for 1st. Miss Northampton, 2nd. Miss Paignton, 3rd. Miss Wigan, 4th. Miss Oban.

Can you put the four winning girls in the right order?

[tantalizer425]

## Tantalizer 426: Drawing conclusions

From New Scientist #977, 27th November 1975 [link]

Those aspiring architects Matthew, Mark, Luke and John were discussing the design test they had taken the week before. The results were not yet public, but there had, of course, been leaks.

Matthew summed the position up: “We all know that there were seven candidates, exactly four of whom passed. None of us here knows how any of the absent candidates fared. None of us yet knows whether he himself passed or failed. Each of us here knows the result of each of the other three present”.

“That is interesting”, said Mark, “and your final sentence is news to me. But I still do not know whether I passed”.

“Matthew’s final sentence was news to me too”, Luke said presently, “but even now I too cannot work out whether I passed”.

On being told that they are bright lads and have deduced all they can, you can discover one result. Whose and what?

[tantalizer426]

## Tantalizer 427: Pub crawl

From New Scientist #978, 4th December 1975 [link]

Peter Pickle has drawn up this handy map of the twenty pubs in his town. On crawling nights he starts with a pint at The Swan and then moves off along the lines stopping at each pub he passes. (He may visit the same pub more than once).

He follows a formula on stepping out of The Swan: P, Q, R, Q, P, Q, P, S, S, P, S, P, Q, R, Q. In the formula P, Q, R and S stand for north, east, south and west (not necessarily in that order). The final Q brings him to The Bull (the red dot on the map) for the first and only time.

Can you mark the Swan on the map?

[tantalizer427]