I would like to learn programming but haven't been able to get started. Advice appreciated, both high-level (you should try learing language X) and low level (you can find a program that will run language X here), the latter has been a particular problem for me, I don't really know how this sort of thing works.
I am currently studying maths and physics, and I have a particular talent for the former, so I would probably do well with a language that plays to that strength. My only actual experience with programming was when my father let me play around with Jython a bit when I was about 13, I had some fun calculating prime numbers and approximating pi but never got any farther.
Thanks in advance for all suggestions.
sum [ i | i <- [1..999], mod i 3 == 0 || mod i 5 == 0 ]
:)
Haskell is amazing for Project Euler. Lots of these problems are one liners in Haskell. Actually I think Project Euler is excellent for learning Haskell tricks specifically, even if you know how to program already. For certain types of tasks, Haskell is an immense force multiplier.
Of course the difficulty with Haskell is that it is both functional and lazy, which means it explicitly hides the causal order of operations from you for other gains (expressiveness, parallelism, etc.) The problem with this is that in order to debug a Haskell program (or any computer program), a human brain needs to construct an accurate causal model of what's going on.
Debugging software is generally the act of repeated interventions into a malfunctioning system to figure out where the malfunction is. Languages like Haskell go against this grain by making it difficult to figure out what your intervention is doing due to the hidden causal order (try inserting a print statement into a Haskell program sometime). This is why, I believe, functional programming never caught on -- functional programs are very convenient for compiler programs to reason about, but very inconvenient for people.