Thinking With Types

This is the first page of a short series of articles that I’ve titled, Thinking With Types.

The TL;DR summary

Unless you’re a library writer, when you program in Java you often don’t work with very complicated types or combinations of types. For instance, given the “programmer categories” that Martin Odersky defined some time ago and Cay Horstmann referenced in his book, Scala for the Impatient:

Application Programmer Library Designer
Beginning [A1]  
Intermediate [A2] Junior [L1]
Expert [A3] Senior [L2]
  Expert [L3]

I think it’s accurate to say that Java library designers in the categories L2, L3, and possibly L1 work with complex data types, but application programmers in the categories A1, A2, and even A3 don’t often get into complex types. I demonstrate this point with some statistics on the next page.

Conversely, if you get into functional programming in Scala, you’ll be working with data types all the time, even in the A1-A3 categories.

This series of blog posts demonstrate what I mean, beginning with some Java/OOP code, and then digging into some Scala/FP code, including an example exercise. In addition to demonstrating the “Thinking With Types” style, I’ll also discuss the benefits of this approach.

If you’re interested, click the link below to begin reading. Or if you’d prefer, you can also download the PDF version of this article series.

books i’ve written