Hacker News new | ask | show | jobs
by schwurb 1566 days ago
> After reading one Python book you can write solid programs in Python.

Okay, so our goal is to write a solid program. Let's see...

> Not so in Haskell, you would need to understand also the extensions of the language which are popular

You can simply go with vanilla Haskell2010. Dealing with strings will be a bit cumbersome, dealing with records will be a bit cumbersome, but you are still at 50% the boilerplate of an average java codebase.

> and understand the best practices (what to use to compose I/O and in which context for example)

No! This is what I was aiming at: You don't have to understand these best practises to have a solid program. Throw everything into one massive do-Block and the resulting program will be at least as solid as the solid python program.

> That and understand how to work with complex types in libraries

I concur that Python documentation is heaps better than Haskell documentation, although we are slowly improving. That said, I think the work is not harder: Learning how to speak with a postgres database or do numerical tasks requires times, period. What is different to Python is that the time spent chasing runtime errors is spent chasing compile errors in Haskell.

Another user linked this comparison of numpy vs. the Haskell equivalent, hmatric. It does not look more complicated in my opinion: https://pechersky.github.io/haskell-numpy-docs/