[Haskell-cafe] instance for (Show ([(String, Int)] -> Int))

Daniel Fischer daniel.is.fischer at googlemail.com
Sat Dec 25 00:58:26 CET 2010

On Saturday 25 December 2010 00:32:38, Aaron Gray wrote:
> Okay great, works this end too, but what does the 'flip' do ???

It flips the order of arguments to calc. You could also write

main = getContents >>= print . (`calc` []) . lexer


flip f = \x y -> f y x


flip f x = \y -> f y x

flip f x y = f y x

More information about the Haskell-Cafe mailing list