### Random Post

### Recent Posts

### Recent Comments

### Archives

### Categories

- article (11)
- enigma (1,158)
- misc (2)
- project euler (2)
- puzzle (40)
- site news (44)
- tantalizer (42)
- teaser (3)

### Site Stats

- 177,972 hits

Advertisements

Programming Enigma Puzzles

5 December 2011

Posted by on **From New Scientist #2815, 4th June 2011** [link]

Joe was asked to arrange a lottery for a local charity. He made a pack of cards with one of just two numbers on each card. One could select to draw any number of cards from the pack. Prizes were awarded according to the total of the numbers on the cards drawn.

Checking numbers which could be allocated prizes, Joe found that below 60 some totals were not achievable, some could be achieved in one way and some in more ways. The total of 59 could only be achieved in one way, but all higher totals could be achieved in more than one way, that is, if Joe had provided enough cards.

What were the two numbers on the cards?

[enigma1649]

Advertisements

%d bloggers like this:

The following Python code runs in 72ms.

Solution:The two numbers on the cards are 4 and 9.