Honestly, category theory is more useful for programming language designers than for programmers in general.
Here are some of the more interesting things it's good for:
1. The lambda calculus is the basis for most functional programming and for closures. The lambda calculus is also tightly linked to Cartesian closed categories. And a huge number of structures in math are either Cartesian closed categories, or at least topoi, which are closely related. This connection can be used to quickly sketch out designs for exotic programming languages.
2. Many simpler categorical ideas map cleanly to programming languages. Functors are parameterized types with `map` functions. Natural transformations correspond to certain kinds of tidy parameterized types. Even monads are basically just nested parameterized types that support `flatten`. And so on.
Now, most of this stuff is pretty shallow category theory. It's mostly definitions. But they're definitions that allow you to draw interesting connections between functional programming, parameterized types, and distant branches of math.
Used right, you can design some pretty unusual languages that fit together cleanly.
> Honestly, category theory is more useful for programming language designers than for programmers in general.
Probably true. However... I wouldn't take that comment too far. IMO if more programmers took interest in the subject, they might begin to see complexity/simplicity they didn't recognize before, and make different language choices, or take a different approach to compositionality.
Here are some of the more interesting things it's good for:
1. The lambda calculus is the basis for most functional programming and for closures. The lambda calculus is also tightly linked to Cartesian closed categories. And a huge number of structures in math are either Cartesian closed categories, or at least topoi, which are closely related. This connection can be used to quickly sketch out designs for exotic programming languages.
2. Many simpler categorical ideas map cleanly to programming languages. Functors are parameterized types with `map` functions. Natural transformations correspond to certain kinds of tidy parameterized types. Even monads are basically just nested parameterized types that support `flatten`. And so on.
Now, most of this stuff is pretty shallow category theory. It's mostly definitions. But they're definitions that allow you to draw interesting connections between functional programming, parameterized types, and distant branches of math.
Used right, you can design some pretty unusual languages that fit together cleanly.