ref: f0b41bea1fc085bf1d3f4a255b7a62402259c8cc
dir: /tests/Guard.hs/
module Guard(main) where
import Prelude
f :: [Int] -> Int
f [x] | x < 0 = 0 - x
| x < 10 = x+1
| otherwise = 99
f [x,y] = x+y
f xs | l < 4 = 0
| otherwise = l
where { l = length xs }
main :: IO ()
main = do
putStrLn $ show [f [0 - 7], f [5], f [20], f [2,3], f [1,2,3], f[1,2,3,4]]