3 ms·
I've tried to learn Haskell a couple times, and I keep running into the basic problem of not being able to search for info on terms like ">>=". If you don't kno
by yobbobandana 15y ago
I've tried to learn Haskell a couple times, and I keep running into the basic problem of not being able to search for info on terms like ">>=". If you don't know what it means, how do you find out? I certainly never knew until reading in this article that they were called "fish" operators. I previously tried to work through 3 or 4 different Haskell tutorials, and still didn't know this.
This article seems very helpful for simply enabling someone with Python experience to learn Haskell.
- tel 15y agoIt's also called 'bind' and should be described in any monad tutorial. Hoogle is a great reference for using Haskell and can successfully find the 'fish' operators[1]. [1]http://www.haskell.org/hoogle/?hoogle=%3E%3E%3D http://www.haskell.org/hoogle/?hoogle=%3E%3E%3D
- tikhonj 15y agoThey aren't actually called "fish" operators, as far as I know. ">>=" is pronounced "bind"; all the other ones are related. I didn't have this problem when learning Haskell because I just started by reading "Learn You a Haskell for Great Good"--which is a great book, coincidentally--and never had to google operators.
- jberryman 15y agoTwo very helpful tips: 1. Look at the types of higher order functions (remember, these operators arent magical syntax, just functions) in ghci with ":t (>>=)" for instance. 2. Use hoogle to find the docs for a function, view its implementation, or search for "that one function" by type P.s. never heard that fish operator business.
- gtani 15y agohttp://www.imada.sdu.dk/~rolf/Edu/DM22/F06/haskell-operatorer.pdf http://www.imada.sdu.dk/~rolf/Edu/DM22/F06/haskell-operatore... http://haskell.org/haskellwiki/Keywords http://haskell.org/haskellwiki/Keywords
- tsuraan 15y agoYou want hoogle: http://www.haskell.org/hoogle/?hoogle=%3E%3E%3D http://www.haskell.org/hoogle/?hoogle=%3E%3E%3D
- sinope 15y agoAlso, an irc client. #haskell on Freenode is stuffed with cool people. You can also borrow the old trick from the Linux community. "WELL I THINK HASKELL SUCKS BECAUSE YOU CAN'T DO X AND Y!" Observe as 50 nerds stumble over each other to help you and show you why Haskell is fucking amazing.