Ask HN: Favourite resources for learning programming type theory?
6 points
1 month ago
| 4 comments
| HN
Hello HN,

Recently, I've been massively enjoying diving into type checkers and how to effectively use them (mostly in Python).

I lack foundational knowledge about the topic (I never studied CS), however, so I am looking for introductory textbooks/blogs/resources on the topic.

More specifically: I see terms being thrown around like "Algebraic sum type", "covariant", "contravariant", and I would like to understand more about what they mean and imply in a practical sense.

Thanks!

kingkongjaffa
1 month ago
[-]
This blog is chock full of these ideas, start here:

https://jrsinclair.com/articles/2019/algebraic-data-types-wh...

reply
stephantul
1 month ago
[-]
Thanks, I will check it out
reply
nbaksalyar
1 month ago
[-]
> introductory textbooks/blogs/resources on the topic

Books on TypeScript, OCaml, Rust or Haskell are usually great resources for that.

There's also "Thinking with Types" which addresses this topic in a lot of depth:

https://thinkingwithtypes.com/

reply
stephantul
1 month ago
[-]
Thanks a lot! Ordered a copy :)))
reply
i_don_t_know
1 month ago
[-]
Types and Programming Languages by Benjamin Pierce, sometimes also referred to as TAPL.
reply
stephantul
1 month ago
[-]
I only just saw this, thanks! Will check it out
reply
randomNumber7
1 month ago
[-]
I enjoyed some papers of Luca cardelli (when I remember the name correctly). There is also one overview/introduction about dependent type systems he wrote.

This is all very theoretically heavy though.

reply
stephantul
1 month ago
[-]
Name is correct, thanks a lot, I'll check it out!
reply