Tuesday this week was Ada Lovelace Day, an annual celebration of the women in science, math, technology, and engineering who have inspired us to become who we are today.
Ada Lovelace Day is doubly important to me: in Grade 3—when I was 8 or 9—the person who introduced me to computer programming was a smart, supportive, and encouraging woman named Lise; now I have a six-year-old daughter named Ada who is smart as a whip, kind and thoughtful, and full of creativity. Lise engendered in me a lifelong joy of programming by teaching me Logo and BASIC on an Apple ][; naturally, I've been eager to give Ada the same chance by teaching her Logo.
But not on an Apple ][. Not on an electronic computer at all. Not just yet. Instead, we've been playing the "Daddy is a Robot Game."
The setup is simple: I used index cards, some sticky labels, a pen, and a pencil. I cut up the labels into small rectangles and wrote the basic Logo commands on them in pen, like this:
Note the blank space to the right of the commands. That's where the programmer writes in the parameter. I gave Ada a pencil with an eraser for this, which helped a lot when it came time to fine-tune and debug the program.
To get things started, I put a few simple commands (FD 2 RT 90 FD 2) on a card. I gave this card to Ada. I explained that when I was a robot, I would follow the instructions on any card that someone hands me. So I became a robot, Ada handed me the card, and I followed the instructions. I ended up running into a wall. Ada was hooked immediately!
Coming up with inspiration for a program turned out not to be a problem. On her own, Ada quickly decided to try and get me to go upstairs.
We designated a place on the floor as "home," and Ada made a card that had just the HOME command on it. At first, she would hand it to me before each run through her program. Then, to make things efficient, she wrote HOME on the back of her program card, then she invented the TURN command, which told me to flip the card over and run the program on the other side. How quickly programmers want to become language designers!
Giving the arguments to LT and RT in degrees was not a problem. Ada is in first grade now, and although she's not completely comfortable with "big" numbers, it was a comfortable stretch for her. She had no trouble remembering 90 degrees is a right angle and 180 degrees reverses course.
But from my point of view, the most amazing part was to watch Ada debug the program. It came naturally to Ada to sit at the table and visualize herself moving through the program as me. She would locate the instruction that caused me to overshoot or undershoot a turn—or run into something—and then erase the number and write in a different one.
Taking this exercise to the computer will be a small step: we're already using real Logo syntax, and we're working with the concept of starting over with a blank slate in the home position (in Logo, you do this with the DRAW command).
I have no idea what Ada will want to do when she grows up. Veterinarian, Astronaut, and Drummer are all on the list. I wouldn't be surprised if she adds Computer Programmer after we take this game onto the computer. Whatever she chooses to do, I think that it can only help that she's making the neural connections now that will give her an intuitive understanding of what it means to program a computer.
If you're a mom or a dad, a teacher, or an uncle or an aunt, why not try this with the 5- and 6-year-olds (or older) in your life? It uses simple supplies you probably have in a desk drawer already, it takes minutes to get started, and it just might lead to a lifetime of fun.