2 minute read

It’s really never too early to start teaching your child to code. You may think, “What’s the point of teaching my kid to code so long before they have any idea what they want to do with their life?” The topic is worth a post of its own, but here are a couple of articles by Beth Werrell and Dan Crow that address how useful “computational thinking” is in a world where everything relies on software. Another possible issue that might come to mind is, “How do I teach my child to code when I don’t even know how?” Thankfully, there are already some really great resources out there to help you learn and teach at the same time. One of my favorite books is Invent Your Own Computer Games with Python which is free online. Another resource, which I haven’t used at all but generally gets good reviews is Teach Your Kids to Code: A Parent-Friendly Guide to Python Programming.

I had the opportunity earlier this semester to team up with a friend of mine to each a few hours worth of Python to her 4th grade class. Let me point out that this isn't nearly enough time to learn a programming language. It's enough time to see what coding is and complete a small project to get the students interested in coding. In 4th grade kids are still learning/perfecting their multiplication tables, so we decided to make a multiplication 2-player game. 

We'll go over two things. First, I'll show you how to easily install Python (it can be a little bit of a challenge on your own). Then, in the next post, I'll present the code that I wrote for class, and describe the basics of what it does. Again, this isn't going to provide enough information for you to "learn how to code". It's a fun first project to show you why learning to code is worthwhile. I would suggest using one of the resources I linked above to figure out all of the details about how the code works.

Installing Anaconda

Anaconda is a version of Python nicely bundled into a convenient package. Here are a list of steps to get up and running 

1. Go to https://www.continuum.io/downloads to download the program. 
2. You'll see options for Windows, OSX, and Linux. Choose the one that works for you.
3. You'll also have the option between Python 2.7 and 3.5. You should choose 3.5 unless you have a very specific reason for choosing 2.7.

4. Begin the download by clicking the 3.5 Graphical Installer I've highlighted in the red rectangle above.
5. Once the download is complete, open the installer.

6. Just follow the defaults and walk through the installer. 
7. Agree to the Terms of Service. 
8. Install for Just me.
9. Accept the default 'Destination Folder'
10. Click the 'Install' button.
11. Once the install as been completely finished, search for 'Spyder' in your computer's search. Look for an icon similar to the one below:

12. Note: Ignore that my icon has Python 2.7, it's what I use because of legacy issues.
13. Select the icon to launch Spyder. It will take a minute to launch. 

14. Congratulations! You're ready to start coding. 

In case you're wondering Spyder is what's known as an IDE. At its simplest, it is just a place to write and run your code. If yours doesn't look exactly the same as mine, don't worry. It's going to look different depending on whether you're using Windows, OSX or Linux.