chickadee » srfi-179 » array-every

array-every pred array1 array2 ...procedure

Assumes that array1, array2, etc., are arrays, all with the same domain, which we'll call interval. Also assumes that pred is a procedure that takes as many arguments as there are arrays and returns a single value.

array-every first applies (array-getter array1), etc., to the first element of interval in lexicographical order, to which values it then applies pred.

If the result of pred is #f, then that result is returned by array-every. If the result of pred is nonfalse, then array-every continues with the second element of interval, etc., returning the first value of pred that is #f.

If pred always returns a nonfalse value, then the last nonfalse value returned by pred is also returned by array-every.

If it happens that pred is applied to the results of applying (array-getter array1), etc., to the last element of interval, then this last call to pred is in tail position.

The functions (array-getter array1), etc., are applied only to those values of interval necessary to determine the result of array-every.

It is an error if the arguments do not satisfy these assumptions.