Kevin Hartnett is a senior writer at *Quanta Magazine* covering mathematics and computer science. His work has been collected in the “Best Writing on Mathematics” series in 2013 and 2016. From 2013-2016 he wrote “Brainiac,” a weekly column for the *Boston Globe*‘s Ideas section.

### The Almost-Proof of Fermat’s Last Theorem

19th century mathematicians thought the “roots of unity” were the key to solving Fermat’s Last Theorem. Then they discovered a fatal flaw.