for_all


for_all(fn, @rest xs1, ...)
      

Return true if applying the function fn to all the corresponding elements of the lists xs1, ... returns true, otheriwse return false.

The lists xs1, ... must be of the same length. Fn should accept as many arguments as there are lists and should not mutate the list arguments.

Examples:

	
for_all(is_symbol, ['a, 'b, 'c])
// true

for_all(^(x, y, z) x + y == z, 
        [1, 2, 3, 4], 
        [1.2, 2.3, 3.4, 4.5], 
        [2.2, 4.3, 6.5, 8.5])
// false
      

Also see:

for_each
map
exists


Core Module Index | Contents