ZVON > References > Haskell reference
| Indexes | Syntax | >> Prelude << | Ratio | Complex | Numeric | Ix | Array | List | Maybe | Char | Monad | IO | Directory | System | Time | Locale | CPUTime | Random

Module: Prelude
Function: all
Type: (a -> Bool) -> [a] -> Bool
Description: returns True if all items in the list fulfill the condition
Related: (&&), and, any, elem, not, notElem, or, (||)
Keywords: and, boolean, list calculation

Example 1

Input: all (<10) [1,3,5,7,9]

Output: True

Example 2

Input: all (==1) [1,1,0,1,1]

Output: False

Example 3

Input: all even [2,4,6,8,10]

Output: True

Example 4

Input: all (\x -> (x*x)/4 > 10) [5,10,15]

Output: False