Help a geek inherit the earth
June 16, 2006 6:45 AM   Subscribe

What language/environment would be a good choice now for a 6-year old math whizz to learn the basics of programming?

My 6-year old son is something of a math whizz. I went up to his room recently and discovered he'd figured out the basics of algebra on his own. He understands negative numbers, and concepts like infinity, and has figured out his own ways of adding together three digit numbers in his head. He gave a speech at school about numbers but left out a lot of his favorite concepts because 'the other kids wouldn't understand'.

I was kind of similar at his age so we enjoy talking about it, although I don't push it on him. (I gave up Math eventually and turned to the humanities, having been pushed by my school too hard).

Anyway, now he's very interested in learning to program computers. When I was his age or a bit older, I learned BASIC... then it seemed LOGO was all the rage for kids.

However I think it would be really good for him to learn something more object-oriented, if such a thing exists, but including procedural aspects.

Ideally it would be something which is capable of writing real programs in (games, I assume) as he develops and if he's interested.

So what language/environment would be good for him to learn on? I think something graphical would be good, as the feedback is so instant, but he's also really enjoys working with words so some textual input/output would be cool.

As I say he's six but his mathematical/logical competency is very high and he has excellent concentration skills, so I wouldn't be afraid of introducing him to something aimed at older kids.

(We run OS X on all our computers here)
posted by unSane to Computers & Internet (35 answers total) 8 users marked this as a favorite
I was going to say Visual Basic was the easiest thing for me to learn, but I'm not sure if it's available on OS X, you might as well get him started with some simple Java Applets.
posted by CXImran at 6:48 AM on June 16, 2006

It would help if you or someone could write a few programs that did something he would appreciate, and then show him variables and expressions that he can change.
posted by StickyCarpet at 6:52 AM on June 16, 2006

My son learned to program at that age using MIT's StarLogo. I didn't want to scare him off by exposing him to OO too early.

Looks like the next step is that he'll be learning Flash.
posted by veedubya at 6:52 AM on June 16, 2006 [1 favorite]

I'd steer him away from BASIC. Not just because it's a little bit harmful to one's understanding of structured programming, but also because it's hard to do anything very interesting. I remember making a video game when I was 8 in Basic. I also remember putting the whole thing away for 10 years after that, too, so...

If, as you say, he figures stuff out on his own, and you don't like to push him, why not set up a few environments for him? Maybe he'll really like LISP, because it's pretty abstracted from the machine, and the technical hurdles present in something like C++ or C (and by technical I mean figuring out includes, makefiles, compiler stuff, etc...) aren't there. I hear everyone likes Python, or Ruby.


Ask him what he'd be interested in really finishing as a program, then figure out where to go from there. I always find a language easier to learn if there's a project married to it from the start.
posted by jon_kill at 6:52 AM on June 16, 2006

My concern about something like Java is that syntactically it's just totally opaque. It doesn't seem like a learning language, unless there's some kid-friendly environment I'm unaware of.
posted by unSane at 6:53 AM on June 16, 2006

How about Flash's Actionscript? It's drawing commands will remind you of LOGO. The latest version of the language -- 2.0 -- is pretty object oriented (class files, inheritance, etc.), and version 3.0 (even move object oriented) is just around the corner.

The nice thing about AS is that it's contained within a very visual environment (a drawing/animation app). And, of course, you can deploy anything you make in a form that everyone can see in their web browser.
posted by grumblebee at 6:55 AM on June 16, 2006

Do not turn your nose up at Logo by any means. It's still a great idea, and you can do tons of math-y things with it.
posted by Wolfdog at 6:56 AM on June 16, 2006

Python is a friendly language, much friendlier and easy to understand than Java. Using Python+Pygame makes is possible to write quite complex games.

You may want to google "rur-ple". Disclaimer: I wrote it... it is designed to teach programming using Python and is intended to be "child friendly". You will need to install python and wxPython before. It is completely free! There were some OS X bugs reported earlier but I believe they have been fixed. Feel free to email me directly with questions/comments/feeback.
posted by aroberge at 6:57 AM on June 16, 2006 [2 favorites]

I'd second Python. While it is OO you can write some pretty complex programs without getting into the nitty gritty. And there is a wealth of tutorials out there.

I, too, learned BASIC as a kid, and I think it didnt help me much. Learning C at that age (8 or 9) was a bit much. I had a 'C for dummies' kind of book and didnt get much out of it.
posted by kableh at 7:00 AM on June 16, 2006

As much as I love Java, it's not a good language for a first-time learner. And there are certainly those who argue it's not good for experienced developers either.

Logo seems like fun. I remember writing recursive code to draw fractals in Logo as a kid. Pretty heady stuff really.

If he understands algebra, maybe a pseudo-programming environment like MatLab or Maple, which can both easily graph complex equations, even in 3D.
posted by GuyZero at 7:02 AM on June 16, 2006

My advice would be that regardless of what you do now, set him up with C/C++ around age 10. I started BASIC at 6 (back 20 years ago), Pascal at 10. I didn't get to C/C++ until 15, and looking back I could have handled it at 10, 12 at the very latest. If your son is as smart as he sounds, he shouldn't have a problem with it and will thank you for getting him into 'core' programming early on while he is brain is still being wired up. Definitely one of my bigger life regrets.
posted by Ryvar at 7:04 AM on June 16, 2006

Actually, I remember that there is a really good java dev tool for beginners that is sutiable for kids: BlueJ. it has a turtle graphics library and some other eay to learn libraries. Plus it's free.
posted by GuyZero at 7:05 AM on June 16, 2006

I bought this book a year or two ago to learn some assembly and found it very accessible (almost too accessible, its really beginner stuff): At 6, it's probably too much (you be the judge), but would be good for later on.
posted by kableh at 7:09 AM on June 16, 2006

for kids.

cuz if he is a math wiz and learns python, he's got scipy and numpy and maya and blender and whole craploads of free scientific and visualization tools used in research to explore with big communities.

this goes along with rur-ple.

children are naturals with oo. adults find it hard because they've been brought up procedurally. for kids, oo is like playing with lego: here's a block. it can be plugged in. it can be extended. there are lots of other blocks like it. some blocks are the same, but also different. all the blocks should play together in some ways. but some blocks are special....
posted by 3.2.3 at 7:24 AM on June 16, 2006

You may want to consider Lego Mindstorms. My kids (9,10) weren't interested in programming but building a robot gave them a reason to learn. The included programming "language" consists of graphical building blocks that may not teach to good programming habits. Alternatively, you can use open source languages that are more traditional (e.g. Not Quite C).

Disclaimer: my assessment is based on the older version.
posted by flickroad at 7:25 AM on June 16, 2006

lego mindstorms (ages 8+) is great for getting into programing. Its not just kids stuff, loads of adults are making really cool robots and programming them with the simple supplied interface. stuff like a robot that solves a rubix cube (thats impressive from lego) or a path finding car have been made. the best thing is its great fun. oh and a lot of robotics and artificial intelligence sites highly reccommend it as an entry point into the field. You can pick up second hand ones on ebay for about 100pounds but some of the older versions dont work on win xp so cross check with lego website. the new one which is a bit swish costs 200quid. Expensive but very versatile. Theres a lot of pieces in the pack which means your only limited by your imagination (well almost). In addtion to maths (which your kid has a good grasp of) programming also requires a different way of thinking and planning and i think the lego kit helps to develop it. Once he sees the benefits of programming (by making an eight legged spider ;> )he will be motivated to learn from some of the other dryer stuff... I mean i never found "Hello world" or "The student grade records" exercises intersting. And thats what you would normally find in a textbook (yawn). I never did LOGO and i didnt have time to read other posts so i dont know if thats interesting.
hope thats of some use.
posted by thegeezer3 at 7:28 AM on June 16, 2006

Blitz Basic is basic for game developers.

Processing allows for instant graphic gratification and is pretty simple.
posted by sexymofo at 7:28 AM on June 16, 2006

I didnt have time to read the previous posts as you can tell from the previous post to mine. ;>
posted by thegeezer3 at 7:29 AM on June 16, 2006

I'd look into Squeak - Alan Kay always had kids partly in mind when he was developing Smalltalk, and Squeak seems to be in that spirit. The immediate nature of Smalltalk would seem like a big plus for kids, and the new Self-inspired Morphic UI makes GUI programming easy.

The only problem will be his eventual frustration when he moves on to the much less powerful mainstream languages...
posted by bonecrusher at 7:46 AM on June 16, 2006

I think C# is a wonderful language, he'll understand C, C++, Java, and any other .NET languages pretty easily after that. There are free development environments on Windows, Linux, and Mac OSX
posted by blue_beetle at 7:48 AM on June 16, 2006

Second (or third, or whatever) python as a cool language. However, perl or C# or something like that might be better, since it'll have actual utility (not that python isn't a great language; just that it's not as commonly used).

However, if utility isn't a concern, you could go with scheme or another lisp dialect. Very math/logic-y, very elegant. Tricky to figure out at times, but it's elegant and may appeal to his sense of adventure.
posted by spaceman_spiff at 7:58 AM on June 16, 2006

I just started teaching computers to kids at a community center (in April), and I'm slowly getting familiar with the different kinds of programs kids really hit on. Mind you, I don't have any solid geeky wiz's yet, but here's what my coworkers have imparted on me about programming for kids.

A program that we use in the centers to get kids into programming is called Kids Programming Language. You start out with really basic lessons learning about points on a grid (some kids have problems with the concept of coordinates right off, so we like to use this online game to help them grasp the concept), and they start by drawing things, then moving things, and it just goes on from there.

I also third the recommendation for Lego Mindstorms. I just got back from a conference for other computer teachers in our organization where I saw a presentation/demonstration, and this just sounds so cool. The robot itself is easy enough because it is, essentially, lego-based, and the programming, from what I gather, sort of becomes natural to the kid. You start off with, as you mentioned, a more object based environment--you move the icons for specific actions into the timeframes (ie, 5 seconds of going forward, etc), and then when the kid moves on to actual programming languages, he understand the concepts behind it, like the if x then y statements and such and finds the language itself much easier. The new Lego Mindstorm model is due out in, I think, August or September. Who knows, robotics could develop into a hobby, or he could get involved with competition for the First Lego League.

Anyhow, good luck, and have fun. :)
posted by monochromaticgirl at 8:03 AM on June 16, 2006

Another vote for Lego Mindstorms. It's got fairly sophisticated programming abilities, but hey, it's LEGO!!. After all he's a 6 year-old. Time to play!!

It's a cool toy, and the programming objectives are very interesting. Great potential for parent-child cooperation, too.

Unless he's extremely precocious, and shows that he's ready to get all abstract with complex languages, I would not clobber the poor guy with Java, C, C## etc just yet.

Don't forget music. Music and math ability can be closely interrelated. Music is very satisfying in a mathematical way (especially Bach)

Before I got into programming, my geeky childhood was filled with (non-Mindstorm) Lego, Meccano, chemistry set, model kits, microscope, telescope, countless electric/electronic lab things. Lots of hikes and outings. These helped me learn basics and to mess with physical and practical implementations of important abstract concepts. I think a kid should get to play with all this stuff before being stuck in a chair in front of a CRT (LCD) screen. just my opinion.
posted by Artful Codger at 8:28 AM on June 16, 2006

I'd definately look at Lego Mindstorms, I think that it's good to get something physical out. The Wiki I linked to has lots of info about the various languages you can program the current RCX in.

I'm sure options like this will be available for the new Mindstorms too, theres a very active community behind Mindstorms.
posted by chrispy108 at 9:38 AM on June 16, 2006

Yet another reccomendation for Mindstorms -- I haven't ever used them, but at age 20, I started to get involved in the AVR hobbyist scene because the microcontrollers used a language I already knew (C) and let me design Really Cool Things that moved/blinked/talked to eachother via bluetooth, etc. I suspect that Mindstorms would open up the same sense of wonder to somebody without a programming background.

I'm torn over whether to reccomend Javascript for your son once he gets comfortable with the basics. I know its held accountable for many of the user-interface evils of the internet, but a few years ago (late high school and early college) I had a great time designing totally nonstandard DHTML interface widgets for my website in Javascript/DHTML. Yes, I committed a lot of sins, but I also learned a lot which remained useful once I realized that I was creating usability nightmares. It has the benefit of letting you make Really Cool Things in relatively short order, too, which makes it attractive from a "ooh, if I teach myself this, I can maybe do ____" perspective.
posted by Alterscape at 9:57 AM on June 16, 2006

I'll add a recommendation for Larry Gonick's Cartoon Guide to the Computer, probably not for your 6-year-old, but maybe as early as 8. I love Gonick's stuff -- accessible, funny, and he doesn't sacrifice accuracy to get there.

I also think the Robo Rally board game is a good way to teach programmer-ish thinking.
posted by Zed_Lopez at 10:15 AM on June 16, 2006

unsane, your description of your son's achievements at six gives me goosebumps. He may not need much help to inherit the earth. Stanislaw Ulam said he thought 80% of creative mathematicians thought in basically geometric terms, 20% in lexical/numeric. Your anecdotes suggest the latter for your son, and I would worry just a bit that pushing him in a geometric direction could frustrate his gift and undermine his confidence.

The discovery of the existence of prime numbers seems to be critical not only for the development of mathematics, but for many mathematicians, too. How about reading a book such as David Wells' Curious and Interesting Numbers and having 'numerical' conversations with your son a la Oliver Sacks and the Prime Twins? He's not all that likely to find a mate who can hold his or her own with him at the average school, and this very necessary role may fall to you.

I've read the other answers to your question, and I barely understand what any of them are even talking about, so I speak here from a position of depthless ignorance. But. Mathematics and computer programming are certainly related. However, they are quite distinct. I wonder, in fact, whether they may even compete for the same parts of the developing brain. No one can say with any confidence what programming languages will be hot in 10 years; I seem to hear programmers complaining about what they must unlearn that they learned 10 years ago, actually. I don't hear anything like that about mathematics.
posted by jamjam at 10:26 AM on June 16, 2006

I've heard great things about Learn to Program from the Pragmatic Programmers. While the author uses Ruby in the book, it's more about the concepts of programming and can be applied toward most any language. And it's child-friendly!
posted by ewagoner at 11:35 AM on June 16, 2006

One of the first programming languages I ever learned was Logo back in 3rd grade. The fun part was the Turtle graphics, because you could visually see the result of your programming. I still have a print out from the calculator that I "programmed". I highly recommend it, since I ultimately ended up getting a CS degree and a programming job :)
posted by geeky at 11:36 AM on June 16, 2006

The Teach Scheme project is having great success teaching programming of the high school level using DrScheme.

DrScheme is a tower of languages, starting from really simple and growing gradually into the professional language that was used to implement DrScheme itself. The programming environment is geared toward beginners, with a lot of effort spent generating good error messages. There is also an introduction to programming book that goes with the environment, and it is available for free on the Web.

I've seen your question come up a few times already. Don Box from Microsoft led a large discussion on this subject on his blog.

There is also this post on the DrScheme mailing list:
posted by gmarceau at 12:18 PM on June 16, 2006

"It is practically impossible to teach good programming to students that have had a prior exposure to BASIC: as potential programmers they are mentally mutilated beyond hope of regeneration." -- Edsger W. Dijkstra

I also recommend Logo or Python, but probably more Logo because graphics will be a lot easier, and kids like graphics.
posted by profwhat at 12:43 PM on June 16, 2006

ToonTalk looks like it might be fun, but it's Windows only -- you'd have to run a virtual machine on your Mac.
posted by Zed_Lopez at 2:04 PM on June 16, 2006

Wow. By accident today, I find out aroberge has made a Quicktime movie demonstrating Rur-ple.
posted by 3.2.3 at 5:13 PM on June 16, 2006

This book might be helpful, if you go the [Windows or Linux] Python route.
posted by SuperSquirrel at 7:35 PM on June 16, 2006

I agree that Mindstorms are a great idea.. Additionally, Robocode might be something he would be interested in.. It reminds me of Mindstorms minus the hardware. You build a Robot (a java object), plug it into their interface and it battles other robots.

IBM developed it as a platform to teach programming--it's open source now.

This article has a nice overview of it (including screen shots):
posted by everybody polka at 12:39 AM on June 17, 2006

« Older My poor right nostril   |   Recovery of Word 6.0 Doc Newer »
This thread is closed to new comments.