Extracted from Pike v7.8 release 866 at 2016-11-06.
pike.ida.liu.se
[Top]
Array

Method Array.any()


Method any

int(0..1) any(array a, function(int(0..0):mixed) predicate, mixed ... extra_args)

Description

Returns 1 if any of the elements in a fulfills the requirement predicate ( a [i], @extra_args ), otherwise 0. The predicate should return non-zero for an element that meets the requirements and zero for those that do not.

Example

Array.any( ({ 2, 4, 6, 8 }), `>, 5 )

See also

all , has_value