### Random Post

### Recent Posts

### Recent Comments

Hugh Casement on Enigma 1070: Time to work | |

Jim Randell on Enigma 1070: Time to work | |

Jim Randell on Enigma 1070: Time to work | |

geoffrounce on Enigma 440: Three X | |

Jim Randell on Enigma 1588: As easy as 1… |

### Archives

### Categories

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

### Site Stats

- 177,568 hits

Advertisements

When it was published I solved this puzzle using a Perl program with 8 nested loops. It ran in 757ms. I recoded it in Python using

`itertools.permutations()`

, and that ran in 617ms. But this program uses the`SubstitutedSum`

solver from theenigma.pylibrary and runs in 50ms.Solution:ENIGMA = 785463.Now the

enigma.pylibrary includes code to invoke theSubstitutedSum()solver directly from the command line this kind of problem can be solved without the need to write a program at all.I thought this was quite fitting as

Enigma 1361was the firstEnigmapuzzle I wrote a program for.A MiniZinc solution shows why the letter O must be zero – otherwise there would be two more solutions

Without the additional condition ELGAR + ENIGMA = NIMROD has three distinct solutions.

Giving the value of any one of the letters leads to a unique solution, with the exception of A=3, which gives two solutions.