Site under construction! :3

any(func: function = (el => el)) ξ―‚

1.0.0 Boolean

Definitionξ―‚
(method) func array.any(func: function = (el => el)) -> bool:
    for element in self:
        return true if func(element)
    return false

Returns true if any element of the array returns true given a specified function, else it returns false.

Pigeonξ―‚
> arr = [0, 1, 2, 3, 4]
> arr.any(el => el > 3)
true

Parametersξ―‚

funcξ―‚

1.0.0 Function Optional

A function object.

If no function is declared, it defaults to checking if items are truthy.