3 ms·
Writing short and clear code in Haskell is definitely easy. As for optimization - it quite often does it for you too!
by miga 14y ago
Writing short and clear code in Haskell is definitely easy. As for optimization - it quite often does it for you too!
- GhotiFish 14y ago!!! I have never met a single person who has said this, let alone capable of following through. If you are capable, I am envious of your determination/natural talent. Or alternatively I and every programmer I know are idiots. Actually both seem like possibilities.
- nilkn 14y ago> Or alternatively I and every programmer I know are idiots. Most programmers haven't taken the time to actually learn Haskell. Haskell only seems hard at first because it incorporates a lot of ideas that other languages do not. For a lot of developers, learning Haskell is a little bit like learning to program from scratch all over again. In that sense, yes, I guess it's hard, but so was whatever language you learned first.
- mbel 14y ago> For a lot of developers, learning Haskell is a little bit like learning to program from scratch all over again. I find this to be the greatest joy of learning a new paradigm, everything is new and unknown, so even simple things are fun (again).
- miga 14y ago> Haskell only seems hard at first because it incorporates a lot of ideas that other languages do not. Indeed, even if you know Haskell, it may take years to master all classes in its standard library and most commonly used modules (like Parsec.)
- swift 14y agoI have to agree with the GP here. Haskell is actually an exceptionally simple, easy language to work with, once you get the basic concepts down. I have occasionally suffered some confusion in Haskell because of poorly documented third-party libraries, but the language itself is a joy.
- viraptor 14y agoI'd add a qualifier that if you know what you're writing and you're writing from scratch, it's relatively easy. Modifying existing programs can present an interesting challenge. For example once you have a working program and decide that actually some value could be read/written using a file instead of computed at runtime and the place you use it is 10 levels deep after calling a non-IO function, you've got two choices. Unsafe IO (then why not use it everywhere) or a minor program redesign. Haskell is the only language where I run into this kind of situation. (it's still quite simple despite this)
- tome 14y agoIf your program is well factored then it probably won't be hard to switch to IO ten levels deep. Bonus: Haskell makes refactoring easy!
- mightybyte 14y agoI'd actually argue that modifying existing programs is where Haskell really shines. Strong static types and purity allow you to know a LOT more about arbitrary bits of code than any other language in mainstream use today.
- ghc 14y agoHaskell has a difficult learning curve, that is all. A person coming to Vim from a modeless editor might feel the same way, but nobody doubts that someone familiar with Vim finds it easy to use. It took me a couple of years to "get" Haskell, but once you do it is very easy write clear, concise code with.
- gtani 14y ago!!! I'm sure you're not an idiot. Have you tried the School of Haskell, it incorporates the minimum viable skills for learning haskell (pulling code apart in the REPL, and understanding type signatures, pattern matches and compiler type check errors) https://www.fpcomplete.com/school/how-to-use-the-school-of-haskell/learning-haskell-at-the-soh https://www.fpcomplete.com/school/how-to-use-the-school-of-h...