The book has thirteen chapters:
- Chapter 1: Getting started.
The basic concepts of F#, including values, types and recursive functions, are
introduced in a manner that allows readers to solve interesting problems from the start.
- Chapter 2: Values, operators, expressions and functions. A thorough introduction to the basic types F# is given, together with a gently
introduction to the notion of higher-order functions.
- Chapter 3: Tuples, records and tagged values. The simplest composite types of F#: tuples and records, are introduced. They allow several values to be grouped together into one component. Furthermore, tagged
values are introduced.
- Chapter 4: Lists. A list is a finite sequence of values with the same type. Standard recursions on
lists are studied and examples illustrating a model-based approach to functional programming
is given.
- Chapter 5: Collections: Lists, maps and sets. The concepts of sets and maps are introduced and the powerful F# collection
libraries for lists, sets and maps are studied and applied in connection with a model-based
approach.
- Chapter 6: Finite trees. The concept of finite tree is introduced and illustrated through a broad selections
of examples.
- Chapter 7: Modules. It is shown how the user can make own libraries by means of modules consisting
of signature and implementation files. Furthermore, object-oriented features of F# are
mentioned.
- Chapter 8: Imperative features. Imperative features of F# are introduced, including the array part of the collection
library and the imperative sets and maps from the .NET framework.
- Chapter 9: Efficiency. The memory management concepts: stack, heap and garbage collection are
described. Tail-recursive functions are introduced and two techniques for deriving such
functions are presented: one using accumulating parameters, the other continuations.
Their efficiency advantages are illustrated.
- Chapter 10: Text processing programs. A variety of facilities for processing text are introduced, including regular
expressions, file operations, web-based operations and culture-dependent string ordering.
The facilities are illustrated using a real-world example.
- Chapter 11: Sequences. A sequence is a, possibly infinite, collection of elements that are computed
on-demand only. Sequence functions are expressed using library functions or sequence
expressions that provide a step-by-step method for generating elements. Database tables
are viewed as sequences (using a type provider) and operations on databases are expressed
using query expressions.
Chapter 12: Computation expressions. The notion of computation expression, which is based on the theory of
monads, is studied and used to hide low-level details of a computation from its definition.
Monadic parsing is used as major example to illustrate the techniques.
- Chapter 13: Asynchronous and parallel computations. This last chapter describes how to construct asynchronous reactive programs,
spending most of their time awaiting a request or a response from an external agent, and
parallel programs, exploiting the multi-core processor of the computer.