Skip to content

Comment on Ask HN: What's the most elegant piece of code you've seen?

Comments

Peter Norvig's Spell Checker http://norvig.com/spell-correct.html

A lot of other code he writes as well.

I really love this blog post by Norvig. Last Christmas I was looking for a trivial project to try Clojure and had a lot of fun working through this. Highly recommended - https://github.com/prakhar1989/clj-spellchecker

Particularly "Solving Every Sudoku Puzzle": http://www.norvig.com/sudoku.html

Also one of my favorites, and also like another reply to this comment I ported it[1] to a language I was learning, Golang.

1. https://github.com/montanaflynn/toy-spelling-corrector

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.