Continuations
Continuation-style programming in Pascal:
- gen.p, generators and streams (e.g., for n-queens problem)
- nonDetParser.p, a non-deterministic parser
- brackets.p, generate all strings consisting of n pairs of matched parentheses, equivalent to enumerate all rooted ordered k-ary trees. Also see Recursion/Brackets/
- See:
- L. Allison, Some Applications of Continuations,
- [The Computer Journal, Vol.31, No.1, pp.9-16, 1988]
- and
- L. Allison, Continuations Implement Generators and Streams,
- L. Allison, Continuations Implement Generators and Streams,
- [The Computer Journal, Vol.33, No.6, pp.460-465, 1990]