Why aren'y you learning yourself a haskell today?

Why aren'y you learning yourself a haskell today?

Other urls found in this thread:

hackage.haskell.org/package/containers-0.5.7.1/docs/src/Data.Map.Base.html#Map
archive.rebeccablacktech.com/g/thread/S54487186#p54487781
storify.com/realtalktech/the-truth-about-haskell-in-industry-startusp-and-b
vex.net/~trebla/haskell/prerequisite.xhtml
twitter.com/NSFWRedditImage

That book is like five years old. Why aren't you reading an up-to-date Haskell introduction instead?

Because I realised everything it can do a normal language can do better and faster. I did go through that book and then through real world Haskell. Waste of time

Because I was learning how to write a lisp interpreter.

because i don't have time to waste today

meme book with a meme title, dropped

Only ebook I've ever paid for. Still worth it

Serious question, is Haskell worth it if you're already familiar with other functional (specifically LISP-like) languages?

The only LISP that's close to modern functional programming might be Clojure. Haskell (especially) goes in-depth into contemporary functional programming.

Yes, Haskell still makes you think in a very different way.

That book sucks and is the definition of babbyslutting

Because I'm learning Fortran 77

are you guys shills?
I've seen this book everywhere, yet no mention in discussions, kind of like shillary

upload a complete pdf
I ain't paying shit nigga

It's actually work-in-progress, but it covers "newer" topics like Foldable, Traversable, and Applicative, i.e. le FTP and AMP. I have two friends using the WIP copy to learn Haskell and I'm impressed of the speed at which they're learning to be cumest. I imagine it'll be more readily available for free as in piss once it's finished this year.

I'm already a Haskell expert. (Feel free to ask me anything related to Haskell)

how do I become a haskell expert
e. g. what concepts should I fully understand

also, do you have tips to make haskell code faster && more efficient

and what are lens useful for

hmm, is that it
op pic has applicatives and I think also mentions foldables and traversables

I hope it has more than that.

wtf is Word8 and the like useful for

>how do I become a haskell expert
Spend all day on #haskell for several years and read blog posts by prominent haskellers

>e. g. what concepts should I fully understand
The type system

>also, do you have tips to make haskell code faster && more efficient
Add strictness annotations. Make your data types strict, and unbox them. Profile your code, figure out where it's spending the time, then optimized that. (Look into threadscope)

Inspect the Core of your critical inner loops and see if it's doing something obviously wrong. Write code that streams or deforests well. (Learn how to use rewrite rules)

Most importantly: Look at other fast and efficient Haskell libraries to see what they're doing differently.

>and what are lens useful for
Multiple things. Lenses (in general) embody some sort of data structure access concept. The key principle is that these are composable and reusable.

Lens is basically an abstraction for working with data structures in a composable, high-level and reusable way. Too hard to summarize, I tried my best.

They're useful for when you want known-size integers.

Word8, Word16, Word32, Word64 = unsigned integers of that size
Int8, Int16, Int32, Int64 = signed integers of that size

(‘Int’ and ‘Word’ have implementation-defined size, so you can't rely on them)

Imagine you're writing a protocol de/serializer, for example.

Oh, also, don't be afraid to write performance-sensitive inner loops in C or assembly and call out to them using the FFI. The FFI is really easy to use.

>type system
what is there more to understand than that types have to align for everything to work?

is there something that type theory teaches you?

>strictness annotation
you mean like specific types such as Int -> Int instead of Num a => a -> a

>data types strict and unbox them
define that, all I think is concrete types like Int when you say strict

>unbox
???


also, is equational reasoning used much? do you personally use it

what do you mean?

Because there is nothing in for me learning a lazy evaluated cuck language.

>what is there more to understand than that types have to align for everything to work?
Plenty more. Types are the most interesting part of Haskell by far.

The rich type theory can give rise to abstraction, safety, performance, reusability, static guarantees, and more. Learning how to design types, how to use the type system, how to derive theorems and useful abstractions from types and how to leverage the power of GHC's 50 billion type system extensions is what lets you write and understand advanced Haskell.

>you mean like specific types such as Int -> Int instead of Num a => a -> a
No. Look up “haskell strictness annotation”. The corresponding language extension is BangPatterns.

>define that, all I think is concrete types like Int when you say strict
You're confusing “strict” with “specific”/“concrete” (or “monomorphic”).

f being strict means, in layman's terms, that evaluating f x requires you to evaluate x first.

In the context of data types, a data type being strict (or more precisely: its constructors being strict) means that returning e.g. Foo x forces x to be evaluated first.

See e.g. the definition of Map: hackage.haskell.org/package/containers-0.5.7.1/docs/src/Data.Map.Base.html#Map

Notice how it uses both strictness *and* unboxing. (Both for performance)

>also, is equational reasoning used much? do you personally use it
Yes and yes. It's mostly used when refactoring or going through code transformations.

what about category theory?

any math background before I delve into type theory and category theory?

I answered this question (and similar ones) in depth a day ago or so

archive.rebeccablacktech.com/g/thread/S54487186#p54487781

Is it ready for production ? Is the doc as good as the python doc' ? Who hire haskell dev' ? How is this better than Lisp ?

F# is more practical

Is it well supported outside Windows?

Yes it is through mono or core clr

thanks family, you've been very helpful

because Elm is more fun and F# is more practical and flexible (multi paradigm, wont force you to use FP in every situation)

>F# more flexible than Haskell
I can tell you know neither of the two

Flexible in that lazy isn't forced and multi paradigm

>I can tell you know neither of the two

But I am user!

storify.com/realtalktech/the-truth-about-haskell-in-industry-startusp-and-b

Is this a "well supported" like c# is "well supported" by mono? Or can you run everything you could on windows on mono, obviously excluding platform specific code?

Do i need math for this?
Also what book for absolute starters ?

>Do i need math for this?
vex.net/~trebla/haskell/prerequisite.xhtml

>do I need math for programming

No, you also don't need any store of power source to run your computer

Why would I learn me a Haskell when I can already Lisp? If I can write purely functional code that cross-compiles into blazing fast C, then why should I bother with a lazily-evaluated overly academic meme lang?

I can tell you know either of the two

All the core libraries are there
Only wpf and other Windows only shit is missing