Repeated application
1 API
apply↑*
apply↑
7.0

Repeated application

Vincent Nys

This package contains two functions which roughly generalize apply (though they do not support keyword arguments or a final list? argument). They can be used for computing a least fixpoint or for succinctly expressing a finite number of recursive calls.

1 API

procedure

(apply↑* f args)  any

  f : procedure?
  args : any
Applies f to args, to the result of said application, etc. until a fixpoint is reached.

procedure

(apply↑ f n args)  any

  f : procedure?
  n : exact-positive-integer?
  args : any
Applies f to args, to the result of said application, etc. until n applications have been performed. If n is 1, this is the same as using apply.