Harlequin Logo
Harlequin
--> Products and Services
Products
--> Advanced Development Software --> MLWorks --> User Stories

· Harlequin · Products · Support · News · Jobs · About Harlequin · Harlepedia · Locations · Navigation ·

MLWorks(tm) User Stories

Why is ML becoming so popular as a teaching language?

Stephen Gilmore of Edinburgh University suggests that there are lots of reasons, some of which he describes below:

"In teaching programming one wishes to convey important concepts and ideas such as data structures, problem decomposition and algorithms. The most challenging concepts for a teacher to convey in these areas are dynamic data structures, modular decomposition of systems and self-referential (recursive) algorithms. ML supports all of these well. It provides a compact and powerful method of describing dynamic data structures. It has a module system supporting separate compilation. It provides definition of functions by pattern matching which greatly simplifies the presentation of recursive functions. In contrast to this, Nicklaus Wirth's Pascal (possibly the last great teaching language prior to ML) forces programmers to build up dynamic data structures from low-level components such as records and pointers. Pascal has no modules. Pascal provides poor support for recursion, leading to students failing to understand this fundamental concept. The same argument (and worse) can be made against languages such as C.

The conclusion that we reach from this is that ML provides much better support for symbolic processing than do traditional procedural languages such as Pascal or C. Symbolic processing makes a better arena for discussing conceptual material than does numerical processing. Conceptual material is the meat of a programming course.

Of course, it is also nice for teachers of programming that ML programs are much shorter than equivalent Pascal or C programs. This is for several reasons. The method of definition of datatypes in ML eliminates the need to introduce intermediate definitions when describing the type of a dynamic data structure (such as a tree or a list) and the provision of pattern matching eliminates the need to program destructors for a constructed value. Type inference makes almost all variable declarations more concise. Garbage collection eliminates the need to program memory management routines.

ML is not a fussy language. It makes simple, well justified, easy to understand choices about such things as the status of first-class values and parameter passing. In other languages these are areas which are often needlessly complex. There are many subsidiary reasons to the above. For example, there are now a variety of good textbooks on ML and ML now has a language standard, and an excellent development environment with MLWorks. Ultimately, progress in science turns upon the replacement of one model of a problem with a better, more consistent, cleaner model. With ML we have a much better model of programming than with the other great languages which came before."


· Harlequin · Products · Support · News · Jobs · About Harlequin · Harlepedia · Locations · Navigation ·

Copyright © 1995-1997 The Harlequin Group Limited. All rights reserved. Last update September 03 1997