## Teaser 2915: £sd

**From The Sunday Times, 5th August 2018** [link]

50 years ago, the coins in circulation were the halfpenny (1/2d), penny (1d), threepenny bit (3d), sixpence (6d), shilling (12d), florin (2 shillings) and half crown (2 shillings and sixpence).

One day, having at least one of each of the above coins, I decided to bank them.

The cashier set out the coins in separate piles, checked them (discovering that the number of coins in each pile was a square), and gave me exactly a 10-shilling note in exchange.

If I told you how many different numbers of coins were in those piles, you should be able to work out the numbers of each coin.

In the order half crown down to halfpenny, how many coins of each type were there?

[teaser2915]

## Jim Randell 4:42 pm

on6 May 2019 Permalink |We know there is at least one of each denomination of coin. So that is 1/2 + 1 + 3 + 6 + 12 + 24 + 30 = 76.5d accounted for, leaving us only 43.5d to worry about, and we need to make this amount from quantities that are 1 less than a perfect square.

It turns out there are 6 different ways to achieve this. Five of them use 3 different quantities, the sixth way uses 4 different quantities, and gives us the solution.

This Python 3 program runs in 73ms.

Run:[ @repl.it ]Solution:The numbers of coins in the piles (from half-crowns down to half-pennies) are: 1, 1, 1, 4, 1, 9, 36.LikeLike

## GeoffR 9:26 pm

on6 May 2019 Permalink |LikeLike