In this chapter, we had an in-depth look at the system of type classes used in purely functional programming. We take a look at the library, that is, a standard library for purely functional programming. We had our first look at the structure of the library and we found out that it is composed of separate models for the type classes, the syntax, and the effect types.
Then, we had an in-depth look at some type classes that are defined by the library. We saw the motivation for their existence, as well as their implementation and usage details. One thing to remember about all of the type classes is that they are not Scala specific. In fact, there is an entire mathematical theory that deals with them in a manner that is independent from any programming language at all. This is called category theory. So, if you know the concepts from one programming language, we are able...