Skip to main content

Mojo function

any

any[IterableType: Iterable](iterable: IterableType) -> Bool

Checks if all elements in the list are truthy.

Parameters:

  • โ€‹IterableType (Iterable): The type of the iterable containing Boolable items.

Args:

  • โ€‹iterable (IterableType): The iterable to check.

Returns:

Bool: True if any element in the list is truthy, False otherwise.

any(value: SIMD[dtype, size]) -> Bool

Checks if any element in the simd vector is truthy.

Args:

  • โ€‹value (SIMD): The simd vector to check.

Returns:

Bool: True if any element in the simd vector is truthy, False otherwise.

Was this page helpful?