repeat   scheme


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/runtime/scheme.xtm

Implementation

(define repeat
  (lambda (n val)
    (let loop ((i n) (out '()))
      (if (<= i 0)
          out
          (loop (- i 1) (cons val out))))))


Back to Index

Similar Entries