length :: [Int] -> Int -- testing 60 combinations of argument values -- looking through 2 candidates of size 1 -- looking through 0 candidates of size 2 -- looking through 1 candidates of size 3 -- looking through 0 candidates of size 4 -- looking through 1 candidates of size 5 -- looking through 0 candidates of size 6 -- looking through 5 candidates of size 7 -- looking through 8 candidates of size 8 -- looking through 23 candidates of size 9 length xs = if null xs then 0 else 1 + length (tail xs) reverse :: [Int] -> [Int] -- testing 60 combinations of argument values -- looking through 2 candidates of size 1 -- looking through 2 candidates of size 2 -- looking through 5 candidates of size 3 -- looking through 9 candidates of size 4 -- looking through 23 candidates of size 5 -- looking through 57 candidates of size 6 -- looking through 147 candidates of size 7 -- looking through 381 candidates of size 8 -- looking through 1014 candidates of size 9 -- looking through 2736 candidates of size 10 -- looking through 7451 candidates of size 11 reverse xs = if null xs then xs else reverse (tail xs) ++ unit (head xs) sort :: [Int] -> [Int] -- testing 60 combinations of argument values -- looking through 2 candidates of size 1 -- looking through 2 candidates of size 2 -- looking through 2 candidates of size 3 -- looking through 6 candidates of size 4 -- looking through 11 candidates of size 5 -- looking through 21 candidates of size 6 -- looking through 49 candidates of size 7 -- looking through 119 candidates of size 8 -- looking through 272 candidates of size 9 -- looking through 625 candidates of size 10 sort xs = if null xs then xs else insert (head xs) (sort (tail xs)) (++) :: [Int] -> [Int] -> [Int] -- testing 60 combinations of argument values -- looking through 3 candidates of size 1 -- looking through 3 candidates of size 2 -- looking through 3 candidates of size 3 -- looking through 12 candidates of size 4 -- looking through 21 candidates of size 5 -- looking through 30 candidates of size 6 -- looking through 66 candidates of size 7 -- looking through 225 candidates of size 8 -- looking through 723 candidates of size 9 -- looking through 1965 candidates of size 10 -- looking through 5544 candidates of size 11 xs ++ ys = if null xs then ys else head xs:(tail xs ++ ys) length :: [Int] -> Int -- testing 60 combinations of argument values -- looking through 2 candidates of size 1 -- looking through 0 candidates of size 2 -- looking through 1 candidates of size 3 -- looking through 2 candidates of size 4 -- looking through 1 candidates of size 5 -- looking through 7 candidates of size 6 length xs = foldr (const (1 +)) 0 xs reverse :: [Int] -> [Int] -- testing 60 combinations of argument values -- looking through 2 candidates of size 1 -- looking through 0 candidates of size 2 -- looking through 1 candidates of size 3 -- looking through 0 candidates of size 4 -- looking through 1 candidates of size 5 -- looking through 8 candidates of size 6 -- looking through 13 candidates of size 7 reverse xs = foldr (flip (++) . unit) [] xs sort :: [Int] -> [Int] -- testing 60 combinations of argument values -- looking through 2 candidates of size 1 -- looking through 0 candidates of size 2 -- looking through 0 candidates of size 3 -- looking through 2 candidates of size 4 sort xs = foldr insert [] xs (++) :: [Int] -> [Int] -> [Int] -- testing 60 combinations of argument values -- looking through 3 candidates of size 1 -- looking through 0 candidates of size 2 -- looking through 0 candidates of size 3 -- looking through 4 candidates of size 4 xs ++ ys = foldr (:) ys xs (\/) :: [Int] -> [Int] -> [Int] -- testing 60 combinations of argument values -- looking through 3 candidates of size 1 -- looking through 3 candidates of size 2 -- looking through 3 candidates of size 3 -- looking through 12 candidates of size 4 -- looking through 21 candidates of size 5 -- looking through 30 candidates of size 6 -- looking through 66 candidates of size 7 -- looking through 225 candidates of size 8 -- looking through 723 candidates of size 9 -- looking through 1965 candidates of size 10 -- looking through 5544 candidates of size 11 xs \/ ys = if null xs then xs else head xs:ys \/ tail xs