Programming. When you read that word what comes to your mind? difficult? dizzy? or even scary?

The reactions mentioned above are normal. You might think that programming is difficult and can be a headache because you have to deal with a lot of data and do coding. What’s more, if you’ve never studied it at all, programming can seem scary.

But did you know? Behind these dizzying things, there are important things that we can learn from programming. Yes, even though we are not professional programmers, we can still learn it.

So what is this important thing?

Before discussing it further, try to read carefully the quotes from Steve Jobs below:

“Everyone in this country should learn to program a computer, because it teaches you to think.”

Steve Jobs

Do you understand the meaning of these quotes? You must be thinking what does it mean to think like a programmer? and how does it become an important thing to learn?

In this article, we will discuss it more. So, if you are interested in knowing it, don’t forget to read the full article below!

## Problem-Solving; Important Lessons From Programming

The important thing that we can learn from programming is problem-solving. We all have faced problems, whether small or big. When faced with this, we are also required to solve it immediately.

Everyone must have their way to solve problems, but can everyone solve them well? certainly not.

Programming teaches us to be able to solve problems. Yes, when coding, a programmer is trained to keep thinking about how to solve various problems. That is why we need to think like programmers.

Some of the ways that are usually done by a programmer in solving problems are:

- Try a solution
- If it fails, try another way
- If it fails, try another method again and keep repeating until you find a solution

The above method is the most common thing done by many people, not just programmers. By following the method above you might be able to find a perfect solution if you are lucky. However, this is not the best strategy to solve the problem.

Yes, if the various solutions you find fail, you have to repeat the same way to find the best solution. This method is tiring and a waste of time.

## Effective Problem-Solving

Well, now is the time for you to know a much more effective way of solving the problem. The right way to solve a problem is to have a framework first and then put it into practice.

The problem now is how to create the right framework to solve the problem? Okay, don’t worry, in this article, you will find out the answer.

Quoted from Freecodecamp.org, based on the book “The 4-Hour Chef” written by Tim Ferris, there are four steps you can take to solve problems, namely understanding, planning, dividing into small problems, and finding solutions when stuck.

## Problem-Solving Framework

### Understand

The first way to solve a problem, of course, is to understand in advance what the problem is being faced. Imagine if you were ordered to do something but do not understand what to do? would be very difficult wouldn’t it? maybe you won’t make it work.

A simple way to know that you understand the problem is when you can explain the essence of the problem in a simple way.

Try to write down the essence of the problem you are facing, make a diagram of the problem, or tell it to someone else. This can help you to understand the problem better.

### Plan

The second way after understanding the problem is to plan a solution.

Imagine if you want to solve a problem but don’t have a plan to do it? very difficult isn’t it? it’s even more likely that you won’t solve the problem well.

That is why you must write a step or strategy to solve the problem. Try to analyze the information about the problem. Then start thinking about some possible steps that could be taken.

You can think like this to make a good plan “When we plan A, then we will get B, and risk C.”

### Divide the problem

The third way to solve problems is to never intend to solve all problems. Maybe you can solve it, but it is certainly very difficult.

An effective way to solve problems is to divide the problem you are facing into several small problems and solve them one by one.

When you have solved these small problems, you can start connecting them to find a solution to the big problem.

This method can make it easier for you to solve problems in detail and more effectively.

### Solution when stuck

After following some of the ways above, you might think what if you get stuck and can’t solve the problem? Sstt… Relax, this is normal but you can handle it. So don’t worry.

In programming, several things can be done to overcome the stuck when solving problems. These methods are;

- Debugging: Try to figure out slowly step by step the solution you are using until you find where you are going wrong.

- Reassess: Review the problem from another perspective. We must be able to look at a problem from a more general perspective.

- Research: do research on the problem. You can look it up on the internet or directly ask someone else. Yes, the problems you face must have been passed by other people. When you have found the answer, then learn how they solve the problem.

Those are some ways that can be done to solve problems and think like a programmer. After knowing all the steps that can be taken in solving problems well, the next thing you can do is practice them. Yes, try to learn to solve problems with a framework like the one mentioned above.

## Now is the Time to Practice the Problem-Solving Method

There is no better way to learn than practice, practice, and practice. By directly practicing it, you will be trained to solve a problem, and when faced with a real problem you will no longer be confused about how to solve it properly.

You can play some fun games to hone your problem-solving skills like Sudoku, Chess, and others. Well, that’s how a programmer thinks to solve a problem, very interesting, isn’t it? even though it looks confusing, it turns out that there are a lot of things that we get from the programming world. One of them is problem-solving skills that are very important for everyone to have.