This page gives brief information on our first book. If you want to find my home page, click here.
Colin Myers, Chris Clack and Ellen Poon
published Prentice Hall, 1993 (301pp)
ISBN 0-13-722075-8
The approach we adopt in this book is to show good software engineering principles by discussion of both correct and incorrect design decisions, using realistic examples. There is no Ackermann function and there are no miracles.
The book was developed during the teaching of functional programming courses to first and second year undergraduates, and both advanced and conversion postgraduate classes at the University of Westminster (formerly PCL) and University College London (UCL)."
The third and fourth chapters explore in depth the heart of the functional style. They are core to SML (and functional) programming and will probably appear quite new to a programmer only familiar with an imperative programming language. In Chapter 3, the list aggregate type is introduced as the most fundamental SML data structure and various styles of recursive programming using lists are investigated. The chapter ends with the design of a program similar to the UNIX utility grep, which is used in subsequent chapters to highlight the expressive power of new features. Chapter 4 introduces the important concept of partial application and demonstrates that functions can be treated as data. It also shows how recursive solutions to programming tasks can be generalized to facilitate control structure abstraction.
Chapter 5 demonstrates a feature of SML that is essential for any production programming: the ability to make blocks of code private to other blocks of code, thereby enabling safer and more re-usable software.
The final two chapters show more advanced programming features. Chapter 6 explore the relationship between data and process by showing SML's powerful facilities for data abstraction and allowing the user to create new types. Chapter 7 introduces the important concept of the module and provides an elegant tool for medium to large-scale program construction.
There are also appendices which cover input and output, imperative aspects of SML, the UNIX-SML interface, and those SML features which are mainly "syntactic sugaring", together with a summary of the initial SML environment and a short discussion of delayed evaluation in SML.
It is recommended that the main body of the book is studied sequentially, and that the reader attempt the exercises as they are encountered. The exercises serve both as a review of the student's current knowledge and also as a commentary on the text: sample solutions are given at the end of the book.