HN Hall of Fame Weekly email

Why Developers Never Use State Machines (2011)

Screenshot of skorks.com captured 2026-07-20
Page preview · captured 2026-07-20

Resurfaced independently across 4 calendar years, with breakout response in 2 of them.

submissions
5
submitters
5
observed span
2011–2023
peak thread · 117 comments
237 pts
latest 20+ return · 2023-01-23
93 pts

Submission timeline

2007–2026

One slot for every year since HN launched. Height is that year's peak points; orange marks a 100+ point or 50+ comment breakout. Select a bar to open its strongest thread.

First comments on top threads

HN comment order

I use them extensively for Appointment Reminder. In addition to modeling the business logic pretty intuitively (particular types of input can cause an appointment to go from :scheduled to :confirmed, :confirmed appointments should not generate additional reminder calls but :scheduled ones should, etc), they're virtually indispensable for doing Twilio applications. I'll have more to say about that at TwilioConf (and will probably post my presentation afterwards). If you do not model call state with a state machine…

patio11·237-point thread·

I've used state machines in the context of hardware design, particularly fpgas and asics. In hardware land, you use a state machine to implement something like software, where your circuit is able to remember what happened earlier so it can behave differently accordingly. It's very crude relative to their software counterparts. They are not as common in software because software is one giant state machine already. Variables hold state, there is state within state (classes, composition etc). Sometimes entities in…

emrah·93-point thread·

> We Don’t Need One Until We Do Exactly that. In my career, I had to use a SM only once, but I really don't know how I could avoid it. The final code was a bit difficult to follow (PHP without Goto), but I drew an ASCII-art comment representing the state machine. And, it was perfectly fine. Fortunately, it was a "write only once" kind of business logic function.

enz·3-point thread·

I have used the state machine abstraction several times throughout the years. Specifically, I used them to replace regular expressions.

tmaly·3-point thread·

The first top-level comment from each of the four biggest threads, in HN’s own order. Excerpts are shortened; open a comment for full context.

Breakout years
2

100+ points or 50+ comments

Total points
339

reference only — not used in Hall rules or ranking

Total comments
211

reference only — not used in Hall rules or ranking

Every submission

DateTitle as submittedByPointsComments
2011-09-01Why Developers Never Use State MachinesFirst breakout · Best threadfogus23792
2016-08-01Why Developers Never Use State Machines (2011)ripitrust31
2019-01-13Why Developers Never Use State Machines (2011)walterbell30
2019-09-04Why Developers Never Use State MachinesHarryBeadle31
2023-01-23Why Developers Never Use State Machines (2011)Hall induction · Latest 20+ point returngreenie_beans93117