Skip to content(if available)orjump to list(if available)

Five Coding Hats

Five Coding Hats

8 comments

·February 4, 2025

NotAnOtter

I like analogy's like this. Not in love with this specific one. It feels like OP thought of the first two hats and then tried to think up other hats, rather than have the nebulas idea of different ways of working and structured the analogy around it.

Analogies should "simplify" not complicate. If you're ever writing an analogy and think "How can I add more meat to this? You know, enough to make it worth sharing in a blog post?" you're on the wrong path.

gorjusborg

I'd also add "Surgeon's hat":

Coding using only exacting, mechanical transformations that can be reasoned to be safe. Used when coding in poorly understood, mission-critical code bases. You do the bare minimum change to get the result, using verifiably safe operations.

disambiguation

Putting on my nitpick hat:

I think scrappy and mcguyver could be the same hat.

I also think chef here is really craftsman, whereas chef makes me think of cooking, as in playful discovery, which is worth its own hat.

As someone else mentioned, war time / emergency this is not a drill hat deserves a spot on the shelf.

Blackarea

Looks like different flavors of doing it "clean" and going "hacky". No real content here imo tbh - Hat analogy is fun though

user3939382

How about the hat where Prod is crashed, your heart is racing, and you throw caution to the wind because things can’t get any worse?

rqtwteye

I think old saying “slow is quick, quick is slow” applies here. Don’t do anything stupid because you are in panic mode.

steveBK123

macgruber hat

throwaway092323

I think this is a very useful framework for "choosing the right tool for the job".

For me personally, there isn't much difference between the Chef's Hat and the Teacher's Hat; the way I make code presentable is the same as how I make it self-documenting. I can tell I did a good job if the person reading my code feels smart.