This function should work for both lists of Int and lists of Integer:
myFunc :: [Integer] -> [Char]
myFunc x = if (sum x `mod` 2 ==1) then "odd" else "even"
But it only works on lists of Integers.
This function should work for both lists of Int and lists of Integer:
myFunc :: [Integer] -> [Char]
myFunc x = if (sum x `mod` 2 ==1) then "odd" else "even"
But it only works on lists of Integers.