home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / mutt / min.mut < prev    next >
Lisp/Scheme  |  1988-09-23  |  232b  |  11 lines

  1.     ;; min.mut : find the the minimum of a list of numbers
  2.     ;; eg (min 1 2 3 4 5) returns 1
  3. (defun min HIDDEN
  4. {
  5.   (INT n)(int i)
  6.  
  7.   (n (arg (i (- (nargs) 1))))
  8.   (while (>= (-= i 1) 0) (if (< (arg i) n) (n (arg i))) )
  9.   n
  10. })
  11.