The Hour Of Code is such an exciting initiative and I am a HUGE, huge believer in coding because of the thinking it requires you to do. I thought to myself how programming changed me as a mathematical thinker – it’s a powerful tool for math modeling. It’s frustrating, but any excuses we ever had for NOT teaching it are quickly evaporating. It’s no longer difficult and confusing for kids. You don’t have to compile, link, or wade through cryptic error messages. Some languages don’t even require you to type. It no longer requires software to install. It’s no longer time-consuming and hard to find information on how to code. Furthermore, coding has gotten sexier and more exciting. It’s colorful. It’s beautiful. It gives you feedback instantly on whether your thinking is right or wrong.

I use Khan Academy and Javascript for coding projects in my 7th grade math class. I like the colorful editor, the easy management of my classes, and the seamless integration with Google Docs.

For your perusal, here are some programming mini-projects we’ve done in 7th grade math you might consider for your Hour of Code – sorted by Common Core Math Standard.

7.EE.4 Use variables to represent quantities in a real-world or mathematical problem, and construct simple equations and inequalities to solve problems by reasoning about the quantities.

7.NS.3 Solve real-world and mathematical problems involving the four operations with rational numbers.

1. Write a program that draws a rectangle and uses variables for the side lengths. Calculate the area and perimeter of the rectangle and display them on the screen.

Video: Using Variables https://docs.google.com/a/psdschools.org/file/d/0B2H_6bIuJrltMjExNjNERmF0TDQ/edit

Video: Expressions https://docs.google.com/a/psdschools.org/file/d/0B2H_6bIuJrltWnMzMlF6RzJlY28/edit

(Clown WS that goes with the video: Clown WS)

Video: The task about rectangles https://docs.google.com/a/psdschools.org/file/d/0B2H_6bIuJrltcVFROGw0RW9OVEk/edit

2. Troubleshoot a program that creates a pep rally graph and averages the attendance at 4 rallies. (Order of operations troubleshooting). I called these my “Wreck-it Ralph” activities, where I presented students with a broken program and tasked them with fixing it. This activity was really great and created some awesome mathematical discussion.

https://www.khanacademy.org/cs/problem-with-averaging/2374277154

7.RP.1: Compute unit rates associated with ratios of fractions, including ratios of lengths, areas and other quantities measured in like or different units.

7.RP.2: Recognize and represent proportional relationships between quantities.

1: “Rates, Ratios, and Fractions: https://www.khanacademy.org/cs/fractions-ratios-rates-with-khan/2450604051

2: “Population Graph” (Wreck-it Ralph troubleshooting) https://www.khanacademy.org/cs/graphing-population-problem/2516563772

7.RP.3: Use proportional relationships to solve multistep ratio and percent problems.

7.G.1: Solve problems involving scale drawings of geometric figures, including computing actual lengths and areas from a scale drawing and reproducing a scale drawing at a different scale.

1. Price of shoes (Wreck-it Ralph): https://www.khanacademy.org/cs/broken-percents/5186416250191872

2. Enlarging and Reducing Snowflakes: https://www.khanacademy.org/cs/enlarging-and-reducing-with-percents/4696957649944576

Video / extension: loops and snowflakes https://docs.google.com/a/psdschools.org/file/d/0B2H_6bIuJrltNVdYNWhwV09sZ3c/edit

Rich math tasks really take on a new dimension when they’re done in a programming context. The feedback is instant, the visuals are rich, the numbers are never easy to work with, yet mental math and estimation are crucial to understanding if your results are reasonable. Abstraction and modeling are inherent in these tasks and they force students to really understand the structure of the mathematics. The students, though, just say they like it. They say they can’t wait to learn more. They say “I’m good at this.” They feel like good problem-solvers and creative people. And you know what? They are.