dodgy x y = x + y * 10
oneIsOne = dodgy 1
dodgy
is a function that has 2 params of type Num
. I get that 10 is polymorphic at this point so can be different types of numbers and therefore Num
instead of something more specific.
oneIsOne
is a function that has one param. According to :t
its type is oneIsOne:: Integer -> Integer
. I don’t see why this isn’t sitll Num
i.e., Num a => a -> a
. What is forcing it to be an Integer
?