### Random Post

### Recent Posts

### Recent Comments

Jim Randell on Enigma 457: Divided by ex… | |

geoffrounce on Puzzle 44: Men-only Mews | |

Jim Randell on Puzzle 44: Men-only Mews | |

Brian Gladman on Enigma 1053: Home truths | |

Jim Randell on Enigma 1053: Home truths |

### Archives

### Categories

- article (11)
- enigma (1,192)
- misc (3)
- project euler (2)
- puzzle (48)
- site news (47)
- tantalizer (51)
- teaser (3)

### Site Stats

- 186,584 hits

Advertisements

The following Python code runs in 51ms.

Solution:The clock was showing 11:54 when the hands were switched.And a slightly more efficient variation (although it’s not noticeably faster).

Here’s a version that finds the two times that are correct first, and then goes back to find when the hands were swapped. It runs in 34ms.

Here is my version: