### Random Post

### Recent Posts

- Enigma 1101: Disappearing numbers
- Enigma 410: Most right
- Tantalizer 475: League table
- Enigma 1102: The Apathy Party
- Enigma 409: Hands and feet
- Puzzle 68: Football and addition: letters for digits
- Enigma 1103: Brush strokes
- Enigma 408: Royal numbers
- Tantalizer 476: Take your partners
- Enigma 1104: Odd and even squares

### Recent Comments

Jim Randell on Enigma 1313: Triangles | |

Jim Randell on Enigma 1101: Disappearing… | |

Jim Randell on Enigma 409: Hands and fee… | |

Jim Randell on Enigma 410: Most right | |

geoffrounce on Enigma 1394: Squares and … |

### Archives

### Categories

- article (11)
- enigma (1,097)
- misc (2)
- project euler (2)
- puzzle (24)
- site news (42)
- tantalizer (25)
- teaser (3)

### Site Stats

- 161,697 hits

Here’s my original Perl code. It’s pretty straightforward and runs in 11ms.

Solution:The lower number is 109989.If you leave the program to run to completion (by removing the

laststatement), you also find that 219978 is the other possible answer.And here’s the same thing in Python. It runs in 51ms.