Domain: learnyouahaskell.com
Stories and comments across the archive that link to learnyouahaskell.com.
Comments · 10
-
Functional Programming
Pick up a copy of Learn You a Haskell
You could easily spend a year banging your head against the wall with functors, monads, etc. -
Learn You A Haskell for Great Good
I'm not a programmer. Lately I started reading through http://learnyouahaskell.com/. I haven't gotten very far yet. My only purpose was to get a handle on the syntax in my xmonad configuration file. I had no idea it could be used to make money.
-
I've had some fun reading
-
... for Great Good!
Two great tutorials for two great languages: Learn You a Haskell for Great Good!: http://learnyouahaskell.com/chapters or Learn You some Erlang: http://learnyousomeerlang.com/ These languages are different from the herd yet particle (Erlang more so). Erlang is used in hundreds of products and systems and it's paradigm matches our real world.
-
Learn You A Haskell
http://learnyouahaskell.com/ Haskell is really good for getting you to think about computation in higher level terms; where does this data go, how am I transforming it, etc. Also, functional languages are much easier to learn if you aren't encumbered with an imperative mindset, but you can easily continue on to imperative from functional. It's also the most beautiful language I know and your son will be a wizard.
-
Re:haskell for the masses? sure, but only...
If only Haskell had some decent tutorials.
I have read a couple, and while reading the second one, I have seen something interesting and I wanted to code it and see how it runs. It was only then I realized that I have read 1.5 Haskell tutorials and I yet can't write/run even Hello World in it. Because none of them even bothered to define what the hell a Haskell program is.
$ ghci
GHCi, version 6.12.1: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Prelude> putStrLn "Hello world!"
Hello world!
Prelude> 1+1
2
Prelude> map (\x -> x*x) [1..10]
[1,4,9,16,25,36,49,64,81,100]
Prelude> foldl1 (+) [1..10]
55
Prelude> :t map
map :: (a -> b) -> [a] -> [b]
Prelude> :t 1
1 :: (Num t) => t
Prelude> :t [1..10]
[1..10] :: (Num t, Enum t) => [t]
Prelude> :t \x->x*x
\x->x*x :: (Num a) => a -> a
Haskell might be nice, but judging a language by type of articles about it, both Lisp and Erlang are light years ahead. They explain how to solve problems at hand - and waste much much less pages signing odes how beautiful and concise the syntax is.
Have you tried Learn You a Haskell for Great Good! ?
Returning to Haskell. I haven't found a single decent explanation of what the hell monad is. Most concise to date is "a monad is a monoid in the category of endofunctors". But neither that has advanced my understanding of Haskell or monads any further.
That's very funny stuff! As for category theory, you don't have to
know it to use monads effectively, so I hope the link will be helpful. -
Scala, Haskell
If you want to learn something new without throwing away all your java experience, you might try Scala. I've heard good things about it (though I have no personal experience with it myself). As functional languages go, I prefer Haskell [1] as my default problem-solving language. You might have trouble finding a Haskell job, but it will teach you things that will be relevant in other languages.
Erlang is an interesting language. I view it as kind of a one-trick pony, but for distributed systems I've not seen anything better.
-
depends what he likes..
I would guess that at an early age you should appeal to their interests, if he is into "web2.0", social networking and that kind of stuff I would guess ruby and lead him towards ruby on rails later on, nice loving language, powerful framework.
If he like games, python and eventually teach pygame or pyglet. Maybe you'll put competing together in PyWeek as a goal.
If none of the above applies but he have a general interest in computers, Haskell is just a jawdroppingly beautiful language. Functional and typed. I just love it. Graham Hutton: Programming in Haskell is a great book for learning Haskell, and if your looking for an online resource there is always Learn You a Haskell For Great Good -
Re:Migt want to learn before your job goes to Indi
Learn you a haskell is certainly a good place to start. Real world haskell is also available on the web, if you want more detail than LYAH provides, particularly as it pertains to building applications that deal with IO, networking, interaction, etc...
-
Re:Python FP -- only slightly like real fp
Python has some features inspired by FP languages including Haskell, but is not anything like real functional programming. Haskell is far more powerful and serious, but also a heck of a lot more difficult to use. Python has a "practicality beats purity" mantra; you could think of Haskell as "purity strikes back".
Stuff Haskell gets you:
Serious native-code compiler whose output can beat compiled C code for some programs (and does darn well on average, see the Alioth shootout)
Ability to use multi-core parallelism, with a library module that treats shared memory as a transactional database, allowing use of shared data between threads while getting rid of all the lock management headaches of languages like Java. This can work because Haskell's functional purity guarantees that the threads won't clobber each other except under circumstances precisely controlled by the library.
Data parallelism allowing computations of list comprehensions to automatically be done in parallel on multiple CPU's
Rigorous type system (nothing like the broken ones like in C or Java that you might be used to) lets you express complex invariants in your datatypes so that errors can be caught by the compiler. This greatly decreases the amount of runtime debugging required.
I could go on, but you get the idea.
Good tutorial: http://learnyouahaskell.com/
More detailed book (full text online): http://book.realworldhaskell.org/
Haskell has a very steep learning curve compared with other languages (or "unlearning curve", as some put it, since you have to forget everything you knew), but learning it (a still ongoing process for me) is one of the most interesting and mind-expanding things I've ever done as a programmer.