The Importance of Computational Thinking

“To reading, writing, and arithmetic, we should add computational thinking to every child’s analytical ability.” –Jeanette M. Wing

What is computational thinking?

Computational thinking lies at the heart of new topics becoming indispensable in the information age — subjects like data science, cryptography, informatics, and artificial intelligence. It is a way of approaching and analyzing computational problems by honing the skills of pattern recognition, decomposition, abstraction, and algorithm design. In a sense, computational thinking is like critical thinking for STEM — whereas critical thinking focuses on finding relationships between ideas in written text, computational thinking is devoted to finding patterns and designing solutions in numerical contexts. Although the concept is immensely important to many STEM fields like mathematics and computer science, it often goes unaddressed directly in schools, and students are thus left without the ability and creativity to solve more difficult computational problems on their own.

But really, what is computational thinking?

It may seem hard to define — even after the lengthy paragraph above, there’s no tangible set of skills that compose “computational thinking.” Unlike, say, arithmetic (the ability to add, subtract, multiply, and divide), or algebra (the ability to solve single- and multiple-variable equations), computational thinking cannot be limited to a specific set of techniques or processes. It is far more ephemeral, far more fundamental. It is the general ability to apply the thought processes of mathematics and computer science to solve problems.

Okay, but if we can’t truly define it, what’s the point?

Just because computational thinking is not easily definable does not mean it is unimportant. Take critical thinking, for example. How would we define that? Well, we could take the dictionary definition: “Critical Thinking: the objective analysis and evaluation of an issue in order to form a judgment.” That may work, but it doesn’t really tell you where or why critical thinking is important. In the same way, we may define computational thinking as: “the objective analysis and evaluation of numbers and functions in order to form a solution.” But that still doesn’t feel very real. Let’s take a look at an example to clarify.

“In a party with 20 people, everyone shakes hands with each other. How many handshakes are there?” This is a fairly common graph theory problem, with a myriad of ways to solve it using more advanced mathematics. But let us assume for a second we’re giving the problem to an eighth grader who has never seen a problem like this before. Now, where does computational thinking come into play?

A primary pillar of computational thinking is the ability is to look for patterns, primarily by testing out smaller cases. A student with good computational thinking skills would not simply sit and stare at the problem, waiting for a formula to pop into their head. Nor would they draw out twenty people and attempt to keep track of every handshake that occurs. No, they would start with 1 person, then 2 people, then 3, and so on.

So let’s see what happens. When there’s just 1 person, no handshakes occur — there’s no one to shake hands with. With 2 people, there’s one handshake between the two. With 3 people, there’s three handshakes (for people A, B, and C: A and B, A and C, and B and C). Now with four people, things get a little tricky. At this point, a student may try drawing out the people and connecting them when they shake hands, in which case he will find there are 6 handshakes. At this point, one of two common solutions may arise, from the power of computational thinking.

First, the student could look for patterns: 0, 1, 3, 6 were the first four numbers. Doesn’t seem to be anything special at first, but upon closer inspection, the numbers go up by 1, then by 2, then by 3, and (presumably) then by 4, and so on! Aha. Computational thinking skills are key to realizing that the Nth number thus corresponds to 1+2+…+N-1. At this point, the student can sit down and add the numbers from 1 to 19, or, realize that a number of pairs are formed (eg: 1+19=20, 2+18=20, 3+17=20, etc.), so there are nine pairs of 20. Adding the 10 in the middle, we get a total of 190.

Or, the student could take a graphical approach. They could draw out each person for small cases, and connect them when they shake hands, as such:

At this point, the student can realize that each person (dot) shakes hands with (is connected to) all others, so there should be N*(N-1) handshakes for N people. However, they must also realize that each handshake is double-counted, once from each side. Thus, they must divide by two, and arrive at N*(N-1)/2. For N=20, we arrive at the same answer, 190.

This simple exercise is a great example of where computational thinking skills come into play. Whereas arithmetic and algebra skills are necessary to solve N*(N-1)/2 for N=20, arriving at that formula requires a different set of less tangible skills, those we call computational thinking. Among them, as we saw, are the initiative and ability to look for patterns, and the ability to abstract problems in graphical representations. Each problem requires a different approach, so fundamentally, computational thinking is the intuition required to find the right way to tackle a math problem.

So, I hope that example cleared up the meaning and importance of computational thinking. That brings me to my last point. Computational thinking is extremely important to every child’s analytical ability, as Jeanette Wing stated in her famous pamphlet. But we aren’t teaching it in school, at least, not focusing on it. Whereas critical thinking skills are key to every English class, computational thinking skills must be foundational to every math class. But that’s not what we see. Instead, we often meet tens of worksheets with times tables or equations for students to repeatedly solve. We’re teaching kids the mechanics behind math, not the ingenuity required to solve problems. And that’s what needs to change.