Hacker News new | past | comments | ask | show | jobs | submit login
Teaching Devina to Code (lifewetravel.com)
30 points by drodio on Apr 6, 2014 | hide | past | web | favorite | 23 comments

I introduced both of my children to arduino at age 7. My son took to it instantly and in weeks was producing things that surprised me. My daughter could not have been less interested; struggled through to few things I showed her forgot it as soon as the lesson was over.

This is how it stayed until the day some random project of my son's involved placing a servo inside a small stuffed toy. The moment my daughter saw the little toy turn and "look" at her, there was nothing in the world that could stop her from trying to learn how to do this herself.

You can't teach your child to code, only present it in a way that will interest them. If you succeed you will not be able to stop them. No one else will be able to either.

“I think the big mistake in schools is trying to teach children anything, and by using fear as the basic motivation. Fear of getting failing grades, fear of not staying with your class, etc. Interest can produce learning on a scale compared to fear as a nuclear explosion to a firecracker.” ― Stanley Kubrick

Or not. One of the things you learn as your kids grow up is that they are not carbon copies of you. They may be interested in the same things you are, or they may not be. I'm in no way trying to disuade anyone from trying to get their kids interested in programming or technology, but if they are not, at a point you have to be willing to admit that they are not.

It may be that for some younger kids, the idea of the computer "doing" something seems more meaningful if the computer is doing something physical.

Couldn't agree more. Show them something really cool they can make on their own and curiosity does the rest. Robotics, TV, a mobile app, physics, whatever moves their world at this point will do.

Correct. When I was younger my interest in coding started when I downloaded some VB app that opened my CD drive and popped up a scary picture. I sat there and thought, I want to know how to do this...

The key is a "hook," a goal, a source motivation. Seeing how a particular technology enables new capabilities and applications is a powerful encouragement to learning it, even for professional adult hackers.

"Make your own computer games" is a hook with many kids (not all). I suggest writing your own implementation of a few very simple games (Hangman, Yahtzee, Boggle, ...) as "lesson prep," this way you're familiar with the strategy and can identify stumbling blocks, needed libraries, etc. I suggest sticking with print / terminal at first (GUI / web stuff introduces a lot of baggage since the model is more complicated).

Then sit next to your daughter and tell her what to type. Of course you should explain what your code does as you go along, and you should ideally do this without looking at your earlier implementation. This helps emphasize the thought process -- you're not just copying magic words from somewhere else, you're using your mind to figure out the right magic words for what you want to do. You should also use an iterative development method -- frequently run it and see the product slowly taking shape.

The initial lessons are more about driving home the fact "You can type in these magic words and make the computer do anything you want" than about the precise details of what the magic words for your particular programming language are, or what they represent. Once the kids realize what sorts of things magic words can do, they are then motivated to learn the particular details. This makes it way easier to teach them, and also encourages them to seek resources on your own.

Source: This was how my dad introduced me to programming at age 5-6. It worked :)

Also, buy the book at http://www.laurenipsum.org/ -- it makes a great bedtime story. Hackers of any age will really enjoy it.

Demonstrate instant reward. If you want a child to be interested in anything, they have to see the reward in it, but it must revolve around something they consider fun. A child's curiosity is based around this one question: "What can I get out of this?"

Many people who started programming young didn't program for the sake of programming or for the aspiration to be a great computer scientist when they grow up. Instead, they programmed for a goal they considered fun. Programming was only an enabler. So, how can programming enable more fun in your child's life?

Take a look at MIT Scratch:


My 7-year old son loves it.

Cool thread, I just started a thread about teaching my own daughter how to code a few hours ago :) First off, congrats on the intention. I believe code literacy is going to be a key educational principle in the 21st century so good for you on taking a step towards that so early.

For me teaching my kids (I've got 3) is not so much about getting their brains stuffed with algorithms and technical stuff, but it's more about giving them access to a world where they can create art. I personally believe coding is more like painting than it is building a bridge. It's a creative process , where things like inspiration make a world of difference.

So the first thing I'd recommend is getting your daughter used to creative activities like drawing, Legos, building stuff, number games, word games, stuff like that. See how she likes it. Then try more advanced things. I started teaching my daughter math early on, since she was about two. We started with counting, then moved up to counting by 2s then backwards, just to see how her mind worked and how she would respond to creative problem solving.

It turned out she loved it and to this day she loves solving problems like those games where you have to almost identical pictures and you have to spot the differences, etc. She also likes playing match-3 type games on the iPhone and playing word games.

So get her started with that. If she sees math as fun, I think that's the first and probably the biggest win.

It might be fun to look at LOGO (maybe UCBLogo[1], free books included) for a first programming language. This has a first-person (turtle) view on a GUI that you move around to make shapes and do math/physics. The idea is that when programming it will be easier for the programmer to associate themselves with the turtle and interaction/exploration in the language will be natural.

The Logo way is pretty different from conventional programming models because it was tailored to be more intuitive than conventional languages like C, JavaScript, or VB. It still offers access to complex, higher order programming concepts like algorithms, AI, automata, etc. Harold Abelson from MIT (SICP) wrote a cool book that covers math/physics in Logo, too.[2]

The creator of the language has an awesome book[3] on how computers can enhance pedagogy and someone wrote a cool blog post on programming for children that mentioned it too[4].

[1] http://www.cs.berkeley.edu/~bh/logo.html

[2] http://www.amazon.com/Turtle-Geometry-Mathematics-Artificial...

[3] http://www.amazon.com/Mindstorms-Children-Computers-Powerful...

[4] http://worrydream.com/LearnableProgramming/

If I can sneak a shameless plug in here, I'm the developer behind Kodable - http://www.kodable.com - an iPad app that introduces kids to programming before they can read.

I know the article said you'd like to keep Devina away from screens for awhile, but we've had kids as young as 18 months using it to learn all about functions, loops, and debugging. Even if she's too young for Kodable, or you'd like to go a different route, we've talked to tons of parents teaching young kids programming and I've learned a lot about the process. I'd love to help any way I can. You (or anyone else interested) can send me an email at jon-at-kodable dot com.

Cool, this is exactly what I'm looking for -- basically things I can introduce her to at as young an age as possible.

I pity the poor little kid. At this stage in life, people (none other than her parents) are already concerned how she is going to contribute to the world. Let her live for a while. Let her explore, find a path that's interesting to her.

I know programming is the future, its the basic skill that will be necessary for all professionals. But let her learn to walk, see, smell, touch, taste the world around her. Sheesh.

I wrote my first HTML when I was 7, it was some now-deprecated html like <body bgcolor="#CCCCFF"> and <font color="blue"></font>. I think I was around 9 or 10 when I learned some JavaScript. Back then I used w3schools because I didn't know any better.

I would recommend to show her what code can do, give her some resources, and allow her to explore and experiment.

Here's a good Board game that has the concept of instructions and executing them: http://boardgamegeek.com/boardgame/18/roborally

Scratch (http://scratch.mit.edu) from MIT is the best tool I've found so far.

The focus is on creating scenes and stories, which I've found has really resonated with my kids.

I am surprised no one has mentioned http://www.codecombat.com/ yet. Or is that too complicated for kids? (i only did the tutorial. it seemed easy and fun)

Making this visual does wonders for kids. I think that's why Alan Kay went with Scratch the way it is.

Hey thanks everyone for your comments. Very, very helpful.

1) ask her if she has any interested in programming.

A huge barrier for many people is they have no understanding of what programming will enable, what it entails, and its varying difficulty levels.

I think there are so many "pre-med" college freshmen because everyone understands the role of a doctor. If programming were more tangible and widely understood, there would be far more people doing it (and luckily this is rapidly happening).

Maybe this is also a good way to teach your daughter college-level abstract algebra.

Applications are open for YC Summer 2019

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact