CH 1
CH 1
PROGRAMMING IN HASKELL
Opinions differ, and it is difficult to give a precise
definition, but generally speaking:
Example Example
2 3
1930s: 1950s:
1
Historical Background Historical Background
1960s: 1970s:
Peter Landin develops ISWIM, the first pure John Backus develops FP, a functional
functional language, based strongly on the language that emphasizes higher-order
lambda calculus, with no assignments. functions and reasoning about programs.
6 7
1987: 1990s:
An international committee starts the development Phil Wadler and others develop type classes and
of Haskell, a standard lazy functional language. monads, two of the main innovations of Haskell.
10 11
2
Historical Background Historical Background
2003: 2010-date:
The committee publishes the Haskell Report, Standard distribution, library support, new
defining a stable version of the language; an language features, development tools, use in
updated version was published in 2010. industry, influence on other languages, etc.
12 13
A Taste of Haskell
f [] = []
f (x:xs) = f ys ++ [x] ++ f zs
where
ys = [a | a xs, a x]
zs = [b | b xs, b > x]
? 14