[Haskell-beginners] Still confused

Marc Gorenstein marc.gorenstein at gmail.com
Mon Jul 1 20:03:06 CEST 2013


Hi Brandon, Darren, and Michael,

Thanks for you responses, but I'm still confused. 

Here are two examples of operator sections. The first takes the infix operator 
/ and turns it into a prefix operator. 

Prelude> let eight_div_by = ((/) 8 )
Prelude> eight_div_by 4
2.0

I get that. But look at the following:  We now have a prefix operator with 
the input on the "wrong" side. 

Prelude> let div_by_eight = ( / 8 )
Prelude> div_by_eight 4
0.5

Why should ( / 8) 4 = 0.5?


Thanks again,

Marc




More information about the Beginners mailing list