- Level Professional
- Duration 35 hours
- Course by École Polytechnique Fédérale de Lausanne
-
Offered by
About
In this course you will learn how to apply the functional programming style in the design of larger Scala applications. You'll get to know important new functional programming concepts, from lazy evaluation to structuring your libraries using monads. We'll work on larger and more involved examples, from state space exploration to random testing to discrete circuit simulators. You’ll also learn some best practices on how to write good Scala code in the real world. Finally, you will learn how to leverage the ability of the compiler to infer values from types. Several parts of this course deal with the question how functional programming interacts with mutable state. We will explore the consequences of combining functions and state. We will also look at purely functional alternatives to mutable state, using infinite data structures or functional reactive programming. Recommended background: You should have at least one year programming experience. Proficiency with Java or C# is ideal, but experience with other languages such as C/C++, Python, Javascript or Ruby is also sufficient. You should have some familiarity with using the command line. This course is intended to be taken after Functional Programming Principles in Scala: https://www.coursera.org/learn/progfun1.Modules
Recap: Getting Started with Tools
- Example Assignment
1
Videos
- Introduction
8
Readings
- Working on Assignments
- Tools Setup (Please read)
- Grading Policy
- SBT tutorial and Submission of Assignments (Please read)
- Cheat Sheet
- Scala Style Guide
- Learning Resources
- Reactive Cheat Sheet
Week 1: For Expressions and Monads
- Quickcheck
- Quickcheck
7
Videos
- Week 1 Introduction
- Recap: Functions and Pattern Matching
- Lecture 1.1 - Queries with For
- Lecture 1.2 - Translation of For
- Lecture 1.3 - Functional Random Generators
- Lecture 1.4 - Monads
- Lecture 1.5 - Exceptional Monads
Week 2: Lazy Evaluation
- Bloxorz
- Bloxorz
6
Videos
- Week 2 Intrduction
- Lecture 2.1 - Structural Induction on Trees
- Lecture 2.2 - Lazy Lists
- Lecture 2.3 - Lazy Evaluation
- Lecture 2.4 - Computing with Infinite Sequences
- Lecture 2.5 - Case Study: the Water Pouring Problem
Week 3: Type-Directed Programming
- JSON Codecs
- JSON Codecs
3
Assignment
- Type-Directed Programming
- Conditional Implicit Definitions
- Implicit Conversions
7
Videos
- Week 3 Introduction
- Lecture 3.1 - Contextual abstractions
- Lecture 3.2 - Using clauses and given instances
- Lecture 3.3 - Type classes
- Lecture 3.4 - Abstract algebra and type classes
- Lecture 3.5 - Context passing
- Lecture 3.6 - Implicit function types
5
Readings
- Motivating Example
- Type-Directed Programming
- Type Classes
- Conditional Implicit Definitions
- Implicit Conversions
Week 4: Functions and State
5
Videos
- Week 4 Introduction
- Lecture 4.1 - Functions and State
- Lecture 4.2 - Identity and Change
- Lecture 4.3 - Loops
- Lecture 4.4 - Extended Example: Discrete Event Simulation
Week 5: Timely Effects
- Calculator
- Calculator
5
Videos
- Week 5 Introduction
- Lecture 5.1 - Imperative Event Handling: The Observer Pattern
- Lecture 5.2 - Functional Reactive Programming
- Lecture 5.3 - A Simple FRP Implementation
- Conclusion
Conclusion
1
Videos
- Conclusion
Auto Summary
Unlock advanced functional programming skills with "Functional Program Design in Scala." This professional-level course, led by expert instructors, delves into designing larger Scala applications using functional programming. Explore concepts like lazy evaluation, monads, and infinite data structures. Ideal for learners with programming experience in Java, C#, or similar languages, this 2100-minute course offers in-depth examples and best practices. Available on Coursera with Starter and Professional subscription options, it builds on foundational knowledge from the "Functional Programming Principles in Scala" course. Perfect for IT and Computer Science enthusiasts aiming to master Scala.

Martin Odersky