Class Information
CS43 - Winter Quarter 2020
General Info
This course covers the fundamentals of functional programming and algebraic type systems, and explores a selection of modern programming paradigms and current research in these areas. Haskell is taught and used throughout the course, though much of the material is applicable to other languages. Topics will be covered from both theoretical and practical points of view, and will include higher order functions, immutable data structures, algebraic data types, type inference, lenses and optics, effect systems, concurrency and parallelism, and dependent types.
- Instructors: Isaac Scheinfeld, Adithya Ganesh, Patrick DeMichele
- Advisor: Jerry Cain
- Time: Tue / Thu: 4:30pm - 5:50pm, usually ending 5:30 for questions
- Location: Building 200, Room 030
- Office Hours: Tue / Wed 1:30pm - 2:30pm, Old Union first floor couches
- Attendance form: tinyurl.com/cs43form
- Feedback form (anonymous): https://forms.gle/qXe5pnES1qxLtjkP6
- Course email: cs43-win1920-staff@lists.stanford.edu
Why Haskell?
Haskell is a pure, lazy language with strong typing. We think this combination of features makes it one of the most elegant programming languages in existence, giving it great expressive power and making it very easy to write and refactor code that does what you think it does. But you’ll have to take the class for us to convince you of this!
Haskell is also a production-ready research language. It presents a unique combination of actual industry usageSee Github’s Semantic, Facebook’s Sigma, and the Elm compiler.
and constant evolution. Many old concepts from Haskell have been incorporated into other languagesExamples include list comprehensions in Python, traits in Rust, and optionals in Swift.
and many new ideas in programming language theory are being worked out in Haskell today.
Resources
There is no formal textbook. Lecture code will be released as material is covered in class. A list of resources can be found here, and will be updated with additional material as the class progresses. We recommend the Haskell wikibook and Learn You a Haskell as primary free references.
Schedule
- Introduction
- Types
- Functor
- Applicative
- Monad
- IO
- Monad Transformers
- Effect Systems
- Optics
- Concurrency & Dependent Types
Assignments
Assignments will be posted here. They will generally be biweekly, and the intent is to provide sufficient starter code to make developing interesting software possible.
- Assignment 1 Out Jan 9 / Due Jan 23.
- Assignment 2 Out Jan 28 / Due Feb 6.
- Assignment 3 Out Feb 10 / Due Feb 20.
- Assignment 4 Out Feb 29 / Due Mar 13.
Prerequisites
There are no formal prerequisites, but we recommend “programming and mathematical maturity.” In terms of Stanford courses, CS107 + CS103 or equivalent experience will suffice, though the material in those courses will not be heavily relied upon.
This course intends to cover a lot of material, and depending on background some topics may be more easily accessible than others. However, the aim is to provide enough background in class for everyone to master the basics of Haskell, and enough flexibility for people to focus on more theoretical or applied problems depending on personal interest.
Expectations
To pass the class (graded C/NC), we expect:
- Attendance in \(\ge\) 80% of lectures. There will be in-class exercises to attempt before working them out as a class, so students should bring a laptop.
- Successful completion of the assignments. Submission deadlines will not be enforced but all work must be completed by the end of the quarter. Solutions will be available upon submission.
Accessibility
We as a course staff are dedicated to making this course accessible to everyone. Please let us know if you have any OAE accommodations or if we can do anything to make the course materials and presentation more accessible. Also, feel free to reach out with any personal questions or concerns about the course. We are always open to making changes!