import System Environment even xs xs even odd xs xs odd main do print

1
2
3
4
5
6
7
8
import System.Environment
even' xs = [x | x <- xs, even x]
odd' xs = [x | x <- xs, odd x]
main = do
print (even' [6, 2, 9, 3, 1, 4, 5, 1, 1])
print (odd' [6, 2, 9, 3, 1, 4, 5, 1, 1])