News for hackers. Stuff that matters.
Re:Updating “101 Basic Computer Games” for 2021 by retrac on Sunday February 28, 2021 @01:48PM (#26295921)
> A friend of mine, when showing him the statement 'x = x + 1' was confused; surely, x cannot also equal x+1.

Some people say a language like Haskell would be no harder, and maybe even easier, for someone with no previous programming or CS experience, than something like C or Python. Comments like that make me wonder if they're right!

(Haskell is a pure functional language. And so has the same reaction as your friend. Variables are immutable. Anything else would be madness.)

Re:Updating “101 Basic Computer Games” for 2021 by richard_todd on Sunday February 28, 2021 @02:02PM (#26296038)
I guess it depends. Maybe for an adult. I learned the rudiments of Atari BASIC when I was seven and the book explained assignment with cartoon pictures of numbers going into boxes. I don’t remember ever being confused about what it meant. You could just try it (oh, X was 7 and now it’s 8, ok). Similarly, control flow wasn’t hard... just follow whichever line number to GOTO next. You could just play with it until it worked. Would seven-year-old me get very far with recursive functions and IO monads? I really don’t think so. So I’ll always have a soft spot for BASIC and how much fun it was. Maybe python in a Jupyter notebook would be a kind of similar experience for today’s kids? But not Haskell.
Re:Updating “101 Basic Computer Games” for 2021 by the_af on Sunday February 28, 2021 @10:09PM (#26299319)
> Would seven-year-old me get very far with recursive functions and IO monads?

A few years back, there was someone who shared here his experience teaching young kids programming with a simplified/visual Haskell and it was pretty cool. It seems kids without programming preconceptions don't find it all that difficult.

Re:Updating “101 Basic Computer Games” for 2021 by fuball63 on Sunday February 28, 2021 @02:19PM (#26296197)
It is interesting to try to think all the way back to the struggles of initially learning and wonder if things that seem difficult now (Haskell, which I know barely anything about) might have made more sense then. I often wonder this about TCL, which looks very weird compared to most languages but is really easy to learn if you remember the "12 rules": https://tcl.tk/man/tcl8.6/TclCmd/Tcl.htm