;;; $Id: length.scm,v 1.1 2004/01/29 00:19:34 leavens Exp $ ;;; AUTHOR: Brian Dorn and Gary T. Leavens (deftype length (forall (t) (-> ((list-of t)) number))) (define length (lambda (l) ;; ENSURES: Result is the length of l (if (null? l) 0 (+ 1 (length (cdr l))))))