411 REFERENCE · Wikibooks
Haskell/List of topics
Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.
Here is a non-exhaustive list of topics covered by the book modules (as of now, covering the first three chapters). Right now it is mostly meant as a tool to make it easier for contributors to visualize the structure of the book as a whole, but it is hoped that it will eventually evolve into a full-fledged study guide.
+ Haskell Basics Old structure
Getting set up
Installation and start-up
Variables and functions
Introduction to variables and functions (with first contact with types)
Immutability of variables
Lists and tuples
Introduction to lists
List building with (:)
Introduction to tuples (with the first example of pattern matching)
Next steps
Source files
Introduction to control structures (if / case, with a teaser to PM)
Piece-wise function definition
Function composition
Let bindings
Type basics
Introduction / motivation
Simple examples (with a teaser to number classes)
Functional types
Introduction to polymorphic types
Type signatures
Type inference
Simple input and output
Introduction / motivation
Actions
Actions and types
IO trail pointers New structure
Getting set up
Installation and start-up
GHCi as a calculator
Defining functions
Source files
Introduction to definitions (functions, variables), first contact with types
Examples only with Int
where clause, layout
Immutability of variables
Truth values (for defining more interesting functions)
Examples with booleans 1 == 2
Guards
More examples
Type basics
Introduction / motivation False < 2
Type signatures, type inference
Int, Bool, Function types
Introduction to polymorphic types, mention of numeric classes for overloading, Double for floating point numbers
Tuples and lists
Introduction to tuples (pattern matching) - useful for returning multiple results
Lists are head + tail, (:) and []
Pattern matching: (:) and [] can also be used on the left-hand side
Building a vocabulary
All syntactic pieces in place, explain that the reader now has to learn lots of types and functions
Example program, exercises!
Cheat sheet: Prelude types, Prelude functions, sorted by category. Each category comes with a short explanation / overview of the most important concepts / functions; link to subsequent chapters for more detailed explanations. Not sure how to organize this.
Functions
Lists
Strings
Input / Output
Working with lists
List comprehensions
Simple input and output
Introduction / motivation
Actions
Actions and types
IO trail pointers
+ Elementary Haskell Old structure
Recursion
Introduction to recursion
List-based recursion (first example of PM on lists)
More about lists
Constructing and modifying lists (spiraling review, needs streamlining, teaser to currying)
Dot dot notation
Infinite lists (first mention of laziness)
head / tail
map (first mention of point-free style; introduces section-functions without commenting)
List processing
Folds (first data structure analysis, more discussions on laziness)
Scans
Filtering
List comprehension (maybe the PM example needs to be sweetened)
Type declarations
Introduction / motivation
data / constructor functions
Algebraic datatype deconstruction (heavy implicit PM usage)
type
Pattern matching
Detailed explanation of PM
Constructors and PM
Introduction to records
As-patterns
PM with literals
PM examples
Control structures
Weakly spiraling review of if (almost redundant)
Spiraling review of case (accounting for PM, comparing to piece-wise)
Guards
More on functions
let / where (seen as private function definitions)
Lambdas
Infix versus prefix (first explicit mention of the syntax variations)
Higher-order functions
Quicksort examples
Associativeness of type signatures (with a very demanding exercise)
Currying New structure
Recursion
This might fit in basics, somewhere between the two modules on lists, maybe?
Introduction to recursion
List-based recursion
More on functions
It seems quite unnatural to have this and Control Structures only at the end of the chapter.
let / where (seen as private function definitions)
Lambdas (note that all pattern matching examples should ideally return to Pattern Matching)
Infix versus prefix (first explicit mention of the syntax variations)
More about lists
One of the existing list modules in Elementary might be merged away.
Dot dot notation
Infinite lists
map / filter (or maybe in basics, alongside comprehensions?)
Folds / Scans (first data structure analysis, more discussions on laziness)
Type declarations
Introduction / motivation
data / constructor functions
Algebraic datatype deconstruction
type
Pattern matching
Detailed explanation of PM
Constructors and PM
Introduction to records
As-patterns
PM with literals
PM examples
Control structures
This chapter makes a lot more sense with the new Basics
if / then / else and comparison to guards
case and comparison to piece-wise
Indentation
Fits with the nearby modules on syntax.
In fact, I can even see how a streamlined version of this could be merged into Control Structures
Layout
Conversion to C-style
Using GHCi effectively
+ Intermediate Haskell Old structure
Modules
Introduction / motivation
Importing
Exporting
Indentation
Layout
Conversion to C-style
More on datatypes
Enumerations (without deriving context - first usage of deriving)
Records
Parametrized types (should focus on usage with constructors)
(newtype is missing)
Trees (and their map and fold)
map and fold for arbitrary datatypes
Class declarations
Classes
Deriving
Inheritance
Prelude classes (diagram only)
(desperately lacks discussion on numerical classes)
Classes and types
Type constraints (on signatures, constructors and instances. Mentions newtype)
(stub-like module)
Keeping track of state
(empty, should be deleted?) New structure
Modules
Introduction / motivation
Importing
Exporting
Building a standalone application
Currently in Haskell in Practice/General Practices. This definitely should be in the Beginner's trail.
Higher-order functions
Having this module tucked at the end of Elementary felt kinda restraining
Quicksort examples
Associativeness of type signatures (with a very demanding exercise)
Currying
More on datatypes
Enumerations (without deriving context - first usage of deriving)
Records
Parametrized types (should focus on usage with constructors)
(newtype is missing)
Other data structures
Trees (and their map and fold)
map and fold for arbitrary datatypes (temporary location)
Classes
The division between the current modules on classes seem arbitrary, so this proposal merges them.
Class declarations
Inheritance
Type constraints (on signatures, constructors and instances. Mentions newtype)
Deriving (note the change in topic order)
Standard classes
The idea is expanding the diagram currently at Class Declarations to a full-fledged module.
This might be a more natural location for exploration of Prelude types than the cheat sheets of Haskell Basics
Also, derivation might fit better if moved here as well (although that might make the module too long)
Note: Keeping track of state should be deleted, there is probably no good reason to attempt such a module without a proper discussion of monads.