It is not included, but they are easily created. This uses the SRFI-1 names any and every but can be renamed some and all:
function array_any(array $array, callable $fn) {
foreach ($array as $value) {
if($fn($value)) {
return true;
}
}
return false;
}
function array_every(array $array, callable $fn) {
foreach ($array as $value) {
if(!$fn($value)) {
return false;
}
}
return true;
}