Prelude> let iif b x y = b x y
Prelude> let problem b = (iif b 'x' 'y', iif b "Ann" "Bob")
< interactive >:1:39:
Couldn't match expected type `Char' with actual type `[Char]'
In the second argument of `iif', namely `"Ann"'
In the expression: iif b "Ann" "Bob"
In the expression: (iif b 'x' 'y', iif b "Ann" "Bob")
no subject
Date: 2012-02-20 07:54 pm (UTC)