Functional Programming with Scala Cats (Udemy.com)
A journey into the world of typeclasses, the Cats library, and the functional way of doing things in Scala
Created by: Leandro Galvan
Last updated December 2022
What you will learn
- Create own typeclasses
- Write and use lawful instances of well-known typeclasses such as Functors, Applicatives, Monads, etc.
- Perform common programming tasks (validation, dependency injection, state management, etc.) in a functional way.
How it compares
Against the other 34 rated Udemy courses in Scala on CourseDuck:
- Rating4.4 out of 5higher than 50% of them
- Reviews310#19 of 35 by number of reviews
- Length12.8 hourslonger than 88% of them
- Last updatedDecember 2022more recently than 55% of them
Course Description
When we start our journey as a Scala developer, our first impression of the language may be that of 'a better Java'. We learn about classes, traits, pattern matching and some other constructs that make our life easier. At some point we come across the amazing higher-order methods such as map, filter and fold. These serve as a great first taste of functional programming.
But what if I told you that there is much more than that? In this course I will show you how standard functional programming practices can help you write code that is more generic, robust and testable.
This course is divided into 3 main sections.
In the first section, we will learn about typeclasses. We will use as a driving example the problem of encoding and decoding objects into and from bytes. By the end of this section you will be able to create your own typeclasses and use the typeclass pattern to write polymorphic code.
In the second section, we will take a look at some of the most common typeclasses in functional programming, including Monads, Applicatives, Functors and many more. We will use the famous Cats library to provide us with their implementations, and we will use Discipline along with ScalaCheck and ScalaTest to test their laws. By the end of this section, you will be able to write lawful instances of these typeclasses for any of your types, and test their validity in an automated manner.
In the third and final section, we will learn to perform many common programming tasks with functional structures. These tasks include:
- Validations via the Validated datatype
- Dependency injection with the Reader monad
- Tracking data in our computations with the Writer monad
- Managing state with the State monad
- Writing stack safe computations with Trampolines
- Making computations lazy with the Eval monad
- Composing monad stacks via monad transformers such as ReaderT and OptionT
- Suspending effects with a simple but useful implementation of the IO monad
I'm a big believer of learning by doing so I've included a lot of in-video exercises, along with quizzes and assignments at the end of each section. I hope you enjoy doing them as much as I enjoyed putting them together!
Without further ado, I want to give you a big welcome to the course and the thrilling world of functional programming!
Instructor Details
- 4.4 Rating
310 Reviews
Leandro Galvan
My name is Leandro Galvan.
I'm a computer scientist from Rosario, Argentina and have been a software engineer for over a decade.
I'm a fierce believer of constant learning, reason why I'm constantly reading books, blogs, taking courses, and trying new and fun stuff!
Over the years I've grown particularly fond of sharing my knowledge with other people in a pragmatic and approachable way.
My current interests are Scala and functional programming. Also Japanese and languages in general :).
More courses by Leandro Galvan
Functional effect handling in Scala with Cats Effect (2022)
4.5 (150 Reviews)
Provider: Udemy
Time: 7.2h
$74.99
More Scala courses
Advanced Scala and Functional Programming (2024)
4.7 (3,560 Reviews)
Provider: Udemy
Time: 13.2h
$39.99
Reviews
By Anonymized User on 4/19/2024
Highly recommended!! The course was entertaining and easy to follow (despite the complex topic). I especially liked all the exercises during the course and the final exercise!
By Anonymized User on 5/18/2023
The structure of the code is poor. The usage of sheets could be convenient for a lector, but it becomes hell for a student, especially after some time when you decide to come back to the material to refresh your knowledge. Examples of the code are sometimes not good as well. Part of the presented code does not compiles until some changes are done implicitly in the following lecture. Some themes, like testing with laws are explained poorly. It's unclear why I need to use it, but not the plain FlatSpec or smth similar.
By Ujjal Dey on 3/31/2023
The tutorial was overall good. The concepts were explained with examples and hands-on. However, the final project was a disappointment. The author could have followed the code-with-me style rather than this fill-in-the-blanks. This could have made the tutorial a bit longer, but who cares. The current approach didn't work.
By Paweł Stępniewski on 11/15/2022
I spent about 12 hours listening to the lectures of this course and additional few hours of cats-effect course and I do not regret it! Leandro`s courses allows you to get know cats in many details in very pleasure way.
By Joop on 9/10/2022
Thorough. Exercises doable. Explanation after exercises sometimes too short. Explanation sometimes needs more information to follow the thought proces.
By Ignacio Gallego Sagastume on 8/11/2022
The course covers a lot of topics in detail, and well explained by Leandro. Be patient and finish it because it will help you a lot in understanding and practicing with monads, applicatives, monoids, and their APIs in the Cats library.
By Dmitry Ochnev on 7/5/2022
The author has done a great job creating this course. Although it is not a complete course about the Cats library, it's still a good introduction, especially while there are not so many courses on this topic. The author answers questions quickly enough and gives good explanations. The course was hard for me but it's really useful.
By Rajagopal Natesan on 5/5/2022
The whole course was wonderful with lot of good examples. Also the clarity in explaining each and every items were great.
By Erle R Granger on 3/11/2022
Great explanation of various topics (like higher kinded types); Lots of good exercises - which imo at my level are super important.
By William DeMeo on 8/7/2021
This course presents the coolest ideas in programming! These methods and techniques are the reason Scala is my favorite language.
Quality Score
No CourseDuck member has rated this course yet. Taken it? Give each part a thumbs up or down.
Overall Score : 88 / 100







