Beginner's Guide to Computational Thinking
Tags: computerscience
Published: 2021-05-06 13:30:10

There are a lot of resources available for learning computer programming, but very few resources for learning the thinking approach required to program. 

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jnmfa1w3raqzvipihoyv.JPG)If the above picture represents programming, then Computational Thinking is the step that comes before programming.

##What is Computational Thinking?##
Computational Thinking is the process of approaching a problem systematically and expressing a solution that can be carried out even by a computer.

It is a blueprint for a computer program. The blueprint can then be implemented using a programming language. 

So, how does Computational Thinking work? It involves 4 elements. Each of these elements arises from a Question.

##1. Problem identification##
Question: Have we identified a problem that is solvable by a computer?

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/taafwrxdtuj7qe7mu4q4.jpg)
Some problems cannot be solved with a computer. We must determine whether a problem is a good candidate for using a computer. It's difficult for computers to solve subjective problems, and hence we come up with problems that consist of data that are usable by a computer. The things to think about here are:
i Topic: What is the big problem you are trying to solve? Can it be stated in a problem statement?
ii Data: What data do you have to contribute to a problem-solving approach? What other data might you need?
iii Feasibility: Can you solve the problem with what you know? What other data might you need?

##2. Decomposition##
Question: Can we break our problems down into smaller sub-problems?
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/bc1nkfv0vk5oouc6g437.JPG)
Once we have a problem statement, the next step would be to break down the problem into smaller sub-problems. These sub-problems then become easier to solve and help in contributing to solve the large problem. Further, these sub-problems could be broken down into even smaller problems. It follows the same notion as elements chemically being composed of single atoms. 

##3. Pattern recognition##
Question: Can we see familiar patterns that can lead us to potential solutions?

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/vlptxqlyknysfacensiw.png)
Finding solutions to similar problems or finding similar problems that have been solved before can help in solving the decomposed problems more efficiently. Consider how the current problem is similar to other problems you have solved in the past. How can these similarities help in coming up with a solution?


##4. Abstraction##
Question: Can we identify non-essentials aspects of our problem that we can ignore?

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lx04463scf9fwn64vt3j.jpg)
Usually, problems have several non-essentials aspects that can be ignored because they only distract us from solving the main problem. This is when we must filter out parts of the problem so that we can concentrate on the necessary aspects that we want to solve. It's when we create a hierarchy of elements and ignore the least relevant ones. This helps with arriving at an effective solution.

 **Note**: Computational Thinking is an iterative non-linear process. These are not steps to follow for solving a problem but rather things to think about when solving a problem. 

**Fun Fact**: Have you heard of the 4 C's of the 21st century: Critical Thinking, Creativity, Collaboration and Communication? Many people argue that Computational Thinking should be the 5th C.