News for hackers. Stuff that matters.
Re:Haskell: The Confusing Parts by adharmad on Monday October 05, 2009 @10:53AM (#861888)
Also does not tackle monads.
Re:Haskell: The Confusing Parts by jrockway on Monday October 05, 2009 @04:05PM (#862646)
Monads are nothing special. "They" somehow acquired some stigma of being "difficult", which caused people to write tutorials to help others understand them. Then the proliferation of tutorials led people to believe that they are difficult to understand, which caused people to write more tutorials. And here we are today, where people avoid a programming language because they think there is some incredibly hard concept they have to master but will never be smart enough to understand.

Anyway, the Typeclassopedia is recommended reading: http://www.haskell.org/haskellwiki/Typeclassopedia

Once you understand the relationship between functions, applicative functors, monads, and arrows, everything will make sense -- they are all the same thing.

(The next issue is, "why would I want this kind of abstraction", but that's best for you to decide on your own.)

Re:Haskell: The Confusing Parts by maxtilford on Monday October 05, 2009 @11:07AM (#861917)
I don't believe tutorials are the right way to figure out monads. For one thing, they aren't as extremely important as they're made out to be, people have just latched on to the name. If you really want to understand monads you have to actually try to write code using them, and struggle through it.
Re:Haskell: The Confusing Parts by barrkel on Monday October 05, 2009 @11:39AM (#861983)
I understand monads just fine. I would like to see a readable explanation of the exact syntactic transformation of the 'do' notation to the actual function that the monad is to logically return the wrapped application of.
Re:Haskell: The Confusing Parts by maxtilford on Monday October 05, 2009 @12:14PM (#862055)
If I'm reading that right, you want to see how do-notation is desugared? The best explanation I could find was http://metafoo.co.uk/practical-monads.txt The two sections "Binding lines together" and "Lines that don't return values" explain it nicely.
Re:Haskell: The Confusing Parts by PoisonInkwell on Monday October 05, 2009 @01:21PM (#862179)
Deliberately. Please note the links to two existing (and very good) monad tutorials... The last thing the Haskell community needs is another lackluster one.
Re:Haskell: The Confusing Parts by johnwatson11218 on Monday October 05, 2009 @07:30PM (#863090)
I had one semester of Haskell in school and thought I knew a thing or two about it. The last thing I attempted in Haskell was the game of blackjack. The two big problems there were user input, and the random numbers that were used to shuffle the deck of cards. Very quickly I had to combine two monads in my code to get anything going and I found it very confusing. It seemed like my entire program had become tainted with the non functional aspects. The tutorials didn't really clear things up either, I'm trying Scala now and that at least seems like it will let me pull in the functional pieces where I can use them.