News for hackers. Stuff that matters.
Re:Yes Silver Bullet (2019) by rsclient on Friday January 24, 2020 @02:01PM (#22141337)
What I dislike about all Haskell examples on every blog is that the writer happily assume that I'm familiar enough with Haskell syntax to understand the code.

In the ordinary method, there's a function name, it takes one input, and returns a result; easy-peasy. Yse, what the method does isn't clear, but at least I know the methods name!

Now lets look at the Haskel fuction. tryAccept :: Int -> Reservation -> MaybeT ReservationsProgram Int

I've read enough of these Haskel enthusiast blogs to know that the name of the function is tryAccept (it helps that it's the same as the C# method), and it takes in two parameters, an int and a Reservation and returns a Mayb of a ReservationProgram. And it's somehow an int, so it's like an enum? That's weird, clearly I don't understand Hasket syntax.

And then later, I'm told that it's simple to figure out what a ReservationsProgram is because there's some enum that doesn't include the word "ReservationProgram" in it.

No offence, but this isn't enticing me to Haskel.

There are no comments on this comment yet.