Here you can find plan and presentations on the Haskell course authored by Dmitry Kovanikov and Arseniy Seroka with subsequent contributions by George Agapov, Ilya Peresadin, Roman Melnikov and Artem Yurchenko.
This course is always under development and always improving constantly because there's no limit for the best Haskell course.
You can always contact us via fp.ctd.itmo [at] serokell.io
All slides: https://slides.com/fp-ctd
- Lecture 0: Why FP and Haskell
- Lecture 1: Stack build tool
- Lecture 2: Basic Syntax
- Lecture 3: Datas, Classes, Instances
- Lecture 4: Basic typeclasses: Monoid. Functor. Applicative
- Lecture 5: Monads
- Slides: Parser combinators and Property-based-testing
- Lecture 6: RealWorld
- Lecture 7: Monad Transformers
- Lecture 8: Speeding up Haskell
- Lecture 9: Parallel and Concurrent Haskell
- Lecture 10: Template Haskell and Lens
- Lecture 11: Brand new DSL world
- Lecture 12: Some fun with kinds
- Lecture 13: Comonads
- Uncovered topics
Templates for homework: https://github.com/ChShersh/fp-homework-templates
- Official resources
- Useful unofficial resources
- About Haskell & some wikis
- Try Haskell in web
- Editors (and IDE's for Haskell)
- Suggested tutorials and other useful online courses
- In Russian
- OHaskell: Для совсем новичков, очень доступно, но очень мало
- anton-k-github: Покрываются более продвинутые вещи + теория
- Stepic: Haskell (part 1): Лучший онлайн курс на русском; прекрасен для самостоятельно изучения
- Stepic: Haskell (part 2): Продолжение лучшего курса
- Dmitry Kovanikov: Обе части курса на Stepic покрывают лишь две трети данного курса на КТ
- Books
- Haskell Programming From First Principles: Best book currently
- LearnYouAHaskell: Free but won't help you much
- Intermediate Haskell: Advanced topics (not yet published)
- Intensive & self-learning courses
- bitemyapp: learnhaskell:
- Dmitry Kovanikov: personally I would recommend «Yorgey's cis194 course»
- Write Yourself a Scheme in 48 Hours
- bitemyapp: learnhaskell:
- In Russian
- Reallife and relatively popular examples of Haskell applications
- Standalone
- pandoc: Converter between different markup formats
- xmonad: Tiling window manager
- hledger: Accounting program
- ShellCheck: Finds bugs in your shell scripts
- Google's CodeWorld: Educational computer programming environment using Haskell
- Cryptocurrencies
- Cardano SL: Cardano Settlement Layer
- RSCoin: Implementation of the RSCoin protocol
- Haskoin: Haskell implementation of the Bitcoin protocol
- A List of companies that use Haskell: ~100 companies (on 26 Aug 2017)
- What Haskell technologies should I probably be using on a daily basis (e.g. Xmonad)?
- Standalone
- FP and Haskell paradigms (also extremely important language features)
- Static types
- Immutability by default
- Purity by default
- Non-null by default
- Sum types
- Lazy evaluation
Introductory presentation: here
- GHC, GHCi
- Haskell project structure
- Stack. Features
- How stack works. Snapshots
.cabal
and.yaml
files- Basic comands
Presentation: https://slides.com/fp-ctd/lecture-1#/
- Introduction to Haskell
- Basic GHCi examples
- Function & operators definition
- Lists and functions on lists
- Haskell syntax
- let (variable declaration)
- where clause
- if expression
- Guards
- case expression
- Higher order functions
- Lambdas (anonymous functions)
- Polymoprhism
- Parametric
- Ad-hoc
- LANGUAGE pragmas
- Currying (aka partial application)
- Pattern matching
- List comprehension
- Function application: (
$
) - Function composition: (
.
) - Lazy evaluation (erathosphene sieve, fibonacci numbers, repmin)
Presentation: http://slides.com/fp-ctd/lecture-2#/
- type: type aliases
- ADT's (algebraic data types):
- product types
- sum types
- data and examples
- Record syntax
- newtype
- Type classes: class
- instance
- deriving
- -XGeneralizedNewtypeDeriving
- Modules cheatsheet
- Church-encoding ADT
Presentation: http://slides.com/fp-ctd/lecture-3#/
- Math in programming
foldr
andfoldl
Foldable
type classFunctor
Applicative
liftAN
& Applicative style programmingAlternative
- List comprehension syntax sugar
Traversable
type class (and instances forMaybe
,List
)- Automatic deriving
- Phantom types
- Type extensions:
Presentation: http://slides.com/fp-ctd/lecture-4#/
- Typed holes
- What is Monad?
Monad
type class- Monad laws
State
monadReader
monadMaybe
as example, philosophy about null-safetyEither
monad instance- Monad laws
Presentation: http://slides.com/fp-ctd/lecture-5-2019#/
- Idea of parsing and parser combinators
Parser
type- Basic parsers
- Instances:
Functor
,Applicative
,Monad
,Alternative
- Usage examples
- Testing
Presentation (part 1): https://slides.com/fp-ctd/lecture-5-part1#/
Presentation (part 2): https://slides.com/fp-ctd/lecture-5-part2#/
- Building IO system from scratch
- Introduce
IO
monad - do notation
- Syntax sugar
- -XApplicativeDo
- -XRebindableSyntax
- Lazy I/O
- FFI
- Mutable data:
IORef
andIOArray
- Exceptions (
catch
,throwIO
, custom exceptions,bracket
, etc.) unsafePerformIO
- Efficient String representations:
Text
,ByteString
Presentation: http://slides.com/fp-ctd/lecture-6#/
- Monads as Effects
- Composing monads
MonadIO
MonadTrans
type classMaybeT
transformerReaderT
transformer- Comparison of transformers and old types
MonadThrow
type classMonadError
type classmtl
style of transformation [//]: # (Didn't find MaybeIO and CoroutineT)
Presentation: http://slides.com/fp-ctd/lecture-7#/
- List concatenation pitfalls and Difference List
seq
,deepseq
,NFData
- -XBangPatterns
foldr
vs.foldl
vs.foldl'
- Irrefutable patterns
- Strict Haskell
- Space leaks
- Deforestation
- Stream Fusion
- Couple words about Rewrite Rules
ST
monad (STRef
,STArray
)
Presentation: http://slides.com/fp-ctd/lecture-10#/
- Concurrency with Haskell lightweight threads.
forkIO
andMVar
. - Synchronization between threads
- Exceptions revisited
Async
- STM (Software Transaction Memory).
STM
,TVar
. - Parallelism with Sparks. Eval monad
- Inspecting your concurrency (ThreadScope)
Presentation: https://slides.com/fp-ctd/lecture-09#/
- Lens
-XCPP
- Template Haskell
Presentation: https://slides.com/fp-ctd/lecture-10-17#/
- GADTs
- Existential type
- Rank N types
- DSL
Presentation: https://slides.com/fp-ctd/lecture-11#/
- Kinds
- -XTypeOperators
- -XDataKinds. Data promotion
- Heterogeneous lists
- Type symbols
- Data and type families
- Free monads
Presentation: https://slides.com/fp-ctd/lecture-12#/
Comonad
type class & motivationIdentity
comonad
- Zippers
- List zipper
- Game of Life
- Type algebra
- Types as functions (sum, product, type variables)
- Type isomorphisms
- Zippers as deriviation: List zipper, Tree zipper
- Comonads as OOP patterns
codo
-notation
(aka method)
Presentation: http://slides.com/fp-ctd/lecture-13#/
Uncovered topics ↑
Unfortunately there're some topics which are great but there is no time for them in this course :(
Generics
- Pragmas: {-# UNPACK #-}, {-# INLINE #-}, {-# SPECIALIZE -#}, {-# RULES #-} etc.
- GHC compilation process, GHC internals & Core language
LiquidHaskell
- -XArrows and
Arrow
PureScript
Agda
- Even more advanced monads: Indexed, Effect & Super- monads
- Zygohistomorphic prepromorphisms