### Random Post

### Recent Posts

- Enigma 426: Time and again
- Enigma 1084: 1-2-3 triangles
- Tantalizer 466: Diplomacy
- Tantalizer 467: Nine men went to mow
- Enigma 1085: Cut and run
- Enigma 425: Them thar’ Hills
- Puzzle 60: Uncle Bungle gets the last line wrong
- Enigma 1086: Stacking trays
- Enigma 424: A round of fractions
- Tantalizer 468: Shell fire

### Recent Comments

Brian Gladman on Enigma 426: Time and agai… | |

Jim Randell on Enigma 426: Time and agai… | |

Jim Randell on Enigma 1084: 1-2-3 triang… | |

Brian Gladman on Enigma 1084: 1-2-3 triang… | |

Jim Randell on Enigma 1084: 1-2-3 triang… |

### Archives

### Categories

- article (11)
- enigma (1,129)
- misc (2)
- project euler (2)
- puzzle (32)
- site news (43)
- tantalizer (34)
- teaser (3)

### Site Stats

- 169,972 hits

Programmatically we can examine all 4-digit numbers, look for ones with 5 distinct prime factors, and then assign them to ages to fit the conditions (which is how I wrote my first program). This Python program takes a more efficient approach. It runs in 34ms.

Solution:The PIN is 9570.The ages are 15, 22 and 29. Which have factors of (3, 5), (2, 11) and (29).

Another variation

HI Arthur,

When the five prime factors are split among the three ages, they can split (1,1,3) or (1,2,2). How did you eliminate the (1,1,3) split?

Although I can see why F and H can only have one or two prime factors, I am not sure why G cannot have three prime factors (c.f. the ‘G in candidates’ test and the only one of (F,G,H) is prime test).

Good point, I hadn’t thought of the 1,1,3 split.

Here is a further development of Arthur’s approach that runs on Python 3. It uses my Python number theory library but can be modified relatively easily to use Jim’s enigma.py.

Hi Geoff,

Isn’t your solution making the assumption that the middle number is a composite? As it turns out, the middle number of the solution is composite, but I’m not sure whether that can be assumed in the search.

Hi Arthur, Two can be a factor of only one of the three ages, and if it was a

factor of either the lowest or highest age, the middle age wouldn’t be

an integer. So, yes, the middle age has 2 as a factor, which makes it

composite (it can’t be 2)

Hi Geoff,

I still can’t see why 2 has to be a factor of the middle integer.

I have worked it out now – the smallest 5 primes other than 2 have a five digit product, 3*5*7*11*13=15015

In fact no prime factor can be greater than 47, as 2*3*5*7*48 = 10080

My memory is like a sieve – I had worked this out for my solution below but when you asked the question I couldn’t remember why! I am hence mightily relieved that you found the answer. I must remember to add more comments as I get older!

My, this one is popular! Mine is essentially the same as Jim’s.