Learning Path: Haskell: Functional Programming and Haskell
3.7 (24 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
233 students enrolled
Wishlisted Wishlist

Please confirm that you want to add Learning Path: Haskell: Functional Programming and Haskell to your Wishlist.

Add to Wishlist

Learning Path: Haskell: Functional Programming and Haskell

Gain expertise of programming in Haskell — an advanced, purely functional programming language.
3.7 (24 ratings)
Instead of using a simple lifetime average, Udemy calculates a course's star rating by considering a number of different factors such as the number of ratings, the age of ratings, and the likelihood of fraudulent ratings.
233 students enrolled
Created by Packt Publishing
Last updated 4/2017
Current price: $10 Original price: $200 Discount: 95% off
5 hours left at this price!
30-Day Money-Back Guarantee
  • 13 hours on-demand video
  • 1 Supplemental Resource
  • Full lifetime access
  • Access on mobile and TV
  • Certificate of Completion
What Will I Learn?
  • Discover how functional programming addresses complexity
  • See a comparison of functional programs with traditional imperative programs
  • Learn the basics of Haskell datatypes and functions
  • Write and deploy a simple web application
  • Structure larger Haskell programs
  • See how to model your problem domain with precise types and how to reap the benefits of doing so
View Curriculum
  • A computer
  • Internet connection
  • Basic understanding or procedural or object oriented programming
  • You need not have any software installed prior to taking up this course. The course will take you through the installation procedure of all the software needed.

What makes functional programming great?

Let’s dive into this course and figure out the reason for the buzz around functional programming.

In this Video Learning Path, we study a purely functional programming language— Haskell—and discover its capabilities.

Packt’s Video Learning Paths are a series of individual video products put together in a logical and stepwise manner such that each video builds on the skills learned in the video before it.

Haskell is a powerful and well-designed functional programming language designed to work with complex data. Its emphasis on purity makes it easier to create rock-solid applications that stay maintainable and error-free even as they grow in scale.

In this Learning Path, you will start with learning the fundamentals and building blocks of Haskell programming language with special emphasis on functional programming.

You will learn how to solve programming problems and gain hands-on experience of creating an application. You will then move on to learn how to write expressions and high-order functions. We will then go on to discuss two other structured forms of interaction: streaming libraries and functional reactive programming.

By the end of this course, you’ll have an in-depth knowledge of various aspects of Haskell, allowing you to make the most of functional programming in Haskell.

To ensure that you get the best of the learning experience, in this Learning Path we combine the works of some of the leading authors in the business.

About the Author

Richard Cook is a staff software engineer at Tableau Software working on high-performance relational database systems. He works primarily in C++ but has experience in a broad range of languages and technologies. He frequently applies functional programming and Haskell experience in his daily work. He organizes the Seattle Area Haskell Users’ Group and is an active member of the Seattle functional programming community. He is currently working on developing a machine learning framework for Haskell.

Hakim Cassimally learned the basics of Lisp 15 years ago and has been interested in functional programming ever since. After Audrey Tang developed the first prototype of Perl6 in Haskell (Pugs), he got seriously interested in Haskell and has written, spoken, and evangelised about learning and writing Haskell since 2006.

Samuel Gélineau is a Haskell developer with more than 10 years of experience in Haskell Programming. He has been blogging about Haskell for about the same time. He has given many talks at Montreal’s Haskell Meetup, and is now co-organizer.

Samuel is a big fan of functional programming, and spends an enormous amount of time answering Haskell questions on the Haskell subreddit, and as a result has a good idea of the kind of questions people have about Haskell, and has learned how to answer those questions clearly, even when the details are complicated. 

Who is the target audience?
  • This course is ideal for anyone with a little experience in imperative or object-oriented programming language and wants to learn about functional programming or Haskell.
Students Who Viewed This Course Also Viewed
Curriculum For This Course
73 Lectures
Fundamentals of Practical Haskell Programming
16 Lectures 02:59:35

This video provides an overview of the entire course.

Preview 04:09

This video takes the user through the steps required to install the Haskell Stack build tool on Windows using Windows 10 Pro as an example.

Installing Stack on Windows

This video takes the user through the steps required to install the Haskell Stack build tool on Mac OS using Mac OS X 10.10.5 Yosemite as an example.

Installing Stack on Mac OS

This video takes the user through the steps required to install the Haskell Stack build tool on Linux using Ubuntu 12.04.5 LTS as an example.

Installing Stack on Linux

This video will develop motivation for learning a new approach to software development and a new and decidedly different programming language.

Preview 06:30

This video will outline the approach to managing complexity that functional programming FP encourages.

The FP Way

This video will talk about what Haskell has in common with other functional programming languages as well as the ways in which it is different.

The Haskell Way

This video will demonstrate some more realistic programs, incrementally built up from simpler programs. It will run them in GHC’s interpreted mode. We will see more Haskell syntax encounter more functions from Haskell’s standard prelude.

Preview 15:42

Haskell is a whitespace-sensitive programming language. It’s worth gaining some comfort with the indentation rules, even though they correspond—for the most part—to the “obvious” way to lay a program out. We’ll relate layout to lexical scoping of names.

Whitespace, Layout, and Scoping

GHCi and Interactive Haskell

Haskell employs a non-strict evaluation strategy which can be strange for newcomers to the language. Furthermore, we will inevitably write buggy code. GHCi has useful debugging capabilities that can allow to address both of these concerns.

Debugging with GHCi

We will drill deeper into values, function application and composition, and the various ways to declare functions.

Preview 24:39

So far, we have only skimmed over types and type signatures. You need to know enough to be able to read function declarations and build our own functions and values.

Types and Type Signatures

We’ve looked at built-in types and values and functions that use them; you need to learn how to define our own composite data types. This will use Haskell’s support for user-defined algebraic data types.

Algebraic Data Types

Haskell’s primary mechanism for implementing abstract data types is the type class. We need to know about some of the common built-in type classes as well as how to implement our own type classes and type class instances.

Type Classes

You learn all about declaring our own ADTs and creating values for them. Before we can really consume ADTs, you need to know how to extract values from them using pattern matching.

Pattern Matching
Learning Haskell Programming
21 Lectures 04:09:57

This video provides overview of the entire course.

Preview 02:58

The aim of this video is to introduce how to install Haskell on your computer.

Installing Haskell

The aim of this video is to introduce how to install Haskell on OS X.

Installation Instructions for OS X

The aim of this video is to introduce how to install Haskell on Windows

Installation Instructions for Windows

The aim of this video is to introduce how to install Haskell on Linux.

Installation Instructions for Linux

We want to get started with Haskell in a quick and engaging way, without having to start with a long lecture on syntax. So, to develop our familiarity with Haskell, we'll explore some of the basics, such as how to use and manipulate numbers and strings using 'ghci,' the interactive interpreter.

Preview 13:03

It's hard to write interesting programs with just simple types such as strings and numbers. In this video, we'll look at built-in data structures such as Lists and Tuples, and see how we might do a simple dictionary lookup using built-in functions and the Maybe type.

Built-in Data Structures

The interactive interpreter is a great tool, but we're not going to be able to write longer programs without breaking our text editor. In this video, we'll look at how to use ghci along with our source code files.

Editing Haskell Source Code

You can't do "Functional Programming" without functions. In this video, you'll learn about how to declare functions in Haskell and some of the important characteristics of Haskell functions—how they work with types, currying, and point-free style.

Introduction to Functions

If you're worried that being a "strongly typed" language meant that Haskell's types would be restrictive, never fear! In this video, we'll see how to define not just synonyms, but new types, including recursive ones!

Building Your Own Data Structures

Now we've created our new data-type, how do we manipulate the data inside it? In this video, you'll learn how to calculate the Expression values that we created in the previous video, and look at how to do pattern matching on lists.

Pattern Matching

To make sure we're taking advantage of a solid structure to develop a more complicated application on, we'll create a project with 'stack.' We'll see how to structure our main module, library functions, and tests and look at how to develop, compile, and test the project.

Preview 11:51

In this video, we'll take the first steps towards declaring and displaying a simple grid of letters.

Setting up the Word Game Grid

So we want to search the grid from left to right, right to left, top to bottom, and diagonally... phew! Let's keep things simple for now by searching just from left to right. We'll explore list manipulation functions and the similarities between the Bool and Maybe types.

Searching for Words

Though we can now search the grid horizontally, we want to do it in all directions. The easiest way to do this isn't to make our function more complicated, but rather to learn how to transform our grid! We'll use a toolkit including 'map', 'reverse', 'transpose', and our own recursive functions to do this.

Searching in All Directions

Although Haskell's type system by itself gives you a lot of reassurance that you're writing correct code, good unit tests can help you maintain and understand your code even better.

Unit Testing the Grid with Hspec

You will learn how to associate every character on the word grid with a set of coordinates such as (2, 3) pointing at its position by row and column. We can accomplish this by learning more about Haskell's list type, including how to work with infinite lists, repeat values, iterate them with the List monad and list comprehensions, and join lists together with zip.

Preview 20:44

Using the grid coordinates from the previous video, we will explore how to declare a Cell datatype and incorporate that into our code. This will also give us a good experience of refactoring code. We'll do this using Haskell's type system.

Fleshing Out the Grid Model

In the previous video, we saw that the search functions couldn't be refactored in a simplistic, mechanical way. We now have to think about how to change a simple string search using 'isInfixOf' into something that searches on characters, but returns a complex Cell type.

Searching the Grid Recursively

The moment we've all been waiting for: we'll now turn all of our hard work learning about functions and data types into an actual game that we can play!

Making the Game Playable

While we can now play our game, it still has a few rough edges. We'll now polish off a few of these. First, we want to create a random jumble of characters in the part of the grid that we're currently displaying with "underscore" characters. Next, we want to highlight each of the found words by uppercasing them.

Some Final Polish
Mastering Haskell Programming
36 Lectures 06:04:10

This video gives an overview of the entire course.

Preview 05:29

In this video, we will install everything you will need in order to follow along with the code I'll be presenting during the course.

Installation and Setup

In this video, we will look at the wide variety of side-effects supported by the IO monad.

IO as a "Sin Bin"

In this video, you will learn the subtleties of exception handling in Haskell, including why throwing exceptions is one of the only side-effect which isn't tracked by Haskell's type system.

Exception Handling

Fewer Sins Using the Free Monad

In this video, you will learn how and when to use unsafePerformIO to execute side-effects within pure code.

Benign Side-Effects Using unsafePerformIO

In this video, we will examine how lazy IO is implemented, and how the same underlying mechanism can be used to express effectful stream transformations

Simple Streaming Using Lazy IO

In this video, we introduce streams and demonstrate how laziness makes it easy to implement streaming algorithms in Haskell.

Preview 09:53

In this video, we explore the consequence of a design in which streams are allowed, guaranteed, or forbidden from terminating after a finite number of elements, and similarly for stream transformers terminating after a finite number of steps.

Composing Finite and Infinite Streams

In this video, we explore two variants of a callback-based APIs: push-based and pull-based.

Who's Driving? Push, Pull… or Both!

In this video, we explore another alternative API in which the focus is on the streams instead of the stream transformers.

Transforming Effectful Streams Using the Free Monad

In this video, we will introduce the fundamental abstractions on which Functional Reactive Programming is based.

Preview 08:41

In this video, we look at the way in which FRP libraries handle state, and compare this approach to the way in which state is handled by traditional callback-based systems.

Local and Global States

In this video, we look at FRP operators which allow the FRP network to be changed dynamically.

Higher-Order Signals and Time Leaks

In this video, we look at three ways to specialize the type of the switch operator in order to eliminate time leaks.

Pure, Monadic, and Arrowized APIs

In this video, we look at the properties of time which are either required or provided by FRP implementations.

Continuous, Synchronous, Total Time

What is "Parallel Programming in Haskell" about, and how does it differ from "Concurrent Programming in Haskell?" We answer those questions by clarifying the meaning of a few terms which are frequently confused.

Preview 11:36

How to specify which parts of an algorithm should be executed in parallel?

Manual Parallelism Using the Free Applicative

In this video, we turn laziness from a source of bugs into a source of parallelism opportunities.

Laziness and Parallelism

In this video, we see how purity and immutability makes Haskell a great fit for writing parallel algorithms.

Purity and Parallelism

In this video, you will learn how to write programs whose outcome is deterministic even though the interleaving of its threads is not.

Deterministic Communication Using IVars

In this video, we look at a generalization of IVars which preserves determinism while allowing more than one thread to modify each variable.

Deterministic Collaboration Using LVars

In this video, we look at a few gotchas when writing code which forks threads.

Preview 04:44

In this video, you will learn how to turn an asynchronous API into a synchronous API and vice versa.

Taming Asynchronous APIs Using ContT

If our problem is not composed of smaller identical subproblems, can we still benefit from concurrency?

Opportunistic Concurrency Using Async

In this video, we draw inspiration from laziness in order to delay blocking for child thread until the last possible moment.

Laziness and Concurrency

In this video, we introduce a way for threads to sleep until another thread wakes them up.

Manual Signaling Using MVars

In this video, we introduce software transactional memory, a radically simpler way to write concurrent programs.

Automatic Signaling Using TVars

In this video, we see how purity and effect-tracking makes Haskell a great fit for writing concurrent algorithms.

Effect Tracking and Concurrency

In this video, we show that while writing code in the style of a combinator library has advantages, making it easier to write distributed programs is not one of them.

Preview 11:31

In this video, we investigate whether writing code in the style of a monad transformer stack also makes it harder to write distributed programs.

Monad Transformers

How can we use more than one architectural style, such as combinator libraries or monad transformers, in the same Haskell program?

Nesting Architectures

In this video, we examine whether microservices are a good fit for a distributed Haskell application.

Precise Types, Program Boundaries, and Microservices

In this video, we optimize the set of requests being sent to a number of other services.

Optimizing Microservice Requests Using Haxl

In this video, we introduce a different way to structure a distributed application, by launching remote threads instead of performing remote calls.

Distributed Concurrent Programming Using Cloud Haskell

This video introduces data structures which are designed to cope with the uncertainties of communication in a distributed application.

CRDTs, Type Class Laws, and Eventual Consistency
About the Instructor
Packt Publishing
3.9 Average rating
8,175 Reviews
58,819 Students
687 Courses
Tech Knowledge in Motion

Packt has been committed to developer learning since 2004. A lot has changed in software since then - but Packt has remained responsive to these changes, continuing to look forward at the trends and tools defining the way we work and live. And how to put them to work.

With an extensive library of content - more than 4000 books and video courses -Packt's mission is to help developers stay relevant in a rapidly changing world. From new web frameworks and programming languages, to cutting edge data analytics, and DevOps, Packt takes software professionals in every field to what's important to them now.

From skills that will help you to develop and future proof your career to immediate solutions to every day tech challenges, Packt is a go-to resource to make you a better, smarter developer.

Packt Udemy courses continue this tradition, bringing you comprehensive yet concise video courses straight from the experts.