Article contents
Functional Pearls
Drawing trees
Published online by Cambridge University Press: 07 November 2008
Abstract
This article describes the application of functional programming techniques to a problem previously studied by imperative programmers, that of drawing general trees automatically. We first consider the nature of the problem and the ideas behind its solution (due to Radack), independent of programming language implementation. We then describe a Standard ML program which reflects the structure of the abstract solution much better than an imperative language implementation. We conclude with an informal discussion on the correctness of the implementation and some changes which improve the algorithm's worst-case time complexity.
- Type
- Articles
- Information
- Copyright
- Copyright © Cambridge University Press 1996
References
- 10
- Cited by
Discussions
No Discussions have been published for this article.