文档介绍:AN INTRODUCTION TO FUNCTIONAL PROGRAMMING THROUGH LAMBDA CALCULUS
Greg Michaelson
Department puting and Electrical Engineering
Heriot-Watt University
arton Campus
Edinburgh EH14 4AS
- 2 -
Preface
Overview
This book aims to provide a gentle introduction to functional programming. It is based on the premises that functional
programming provides pedagogic insights into many aspects puting and offers practical techniques for general
problem solving.
The approach taken is to start with pure λ calculus, Alonzo Church’s elegent but simple formalism putation,
and add syntactic layers for function definitions, booleans, integers, recursion, types, characters, lists and strings to
build a highish level functional notation. Along the way, a variety of topics are discussed including arithmetic, linear
list and binary tree processing, and alternative evaluation strategies. Finally, functional programming in Standard ML
MON LISP, using techniques developed throughout the book, are explored.
The material is presented sequentially. Each chapter depends on previous chapters. Within chapters, substantial use is
made of worked examples. Each chapter ends with exercises which are based directly on ideas and techniques from
that chapter. Specimen answers are included at the end of the book.
Readership
This book is intended for people who have taken a first course in an imperative programming language like Pascal,
FORTRAN or C and have written programs using arrays and sub-programs. There are no mathematical prerequisites
and no prior experience with functional programming is required.
The material from this book has been taught to third year puter Science students and to post
graduate Knowledge Based Systems MSc students.
Approach
This book does not try to present functional programming as plete paradigm puting. Thus, there is no
material on the formal semantics of functional languages or on transformation and implementation techniques. These
topics are