Comment

Comment by evincarofautumn

Linear algebra got a lot easier for me when I realised that matrices are just linear functions, and matrix multiplication is function composition.

Abstract algebra and category theory give you incredibly useful program and API structuring techniques; you can get lots of nice properties for free by following these well-worn existing patterns, even more so than OOP design patterns. We make use of them a lot in Haskell, but they’re basically language-agnostic.

Even simple algebraic manipulations, like noticing that “return” is distributive over a conditional:

    if x then return y else return z

    return (if x then y else z)
Are very useful for restructuring programs to be more readable.

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton