What is programming

To put it simply programming essentially is telling the computer what to do. You give it a list of instructions – do X, if you can’t do X then do Y etc.

It’s usually done in a written form using a programming language. It’s a bit similar to a normal language like English – it has certain rules for doing various things. For example, you may have a rule in to end a sentence with a punctuation or some other symbol. In a programming language you may have a rule to end an instruction with a semicolon.

A question that may come up in your mind is why programming is sometimes considered to be difficult? The thing is that unlike humans, a computer is very literal minded. It will do everything you ask and nothing else which is something some people like about them. But this also does mean that you have to instruct everything in detail. As an analogy let’s say you asked a friend to make you a sandwich. That wouldn’t be a problem. He would just make you one. If there wouldn’t be any bread, he would figure something out – either inform you about it, or just go and buy some. However, a computer wouldn’t act that way, if you would tell it to make a sandwich and that’s it, it wouldn’t have any idea on what to do if there’s no bread. You would have to explicitly instruct it to go to the shop. Sounds simple, but what if there’s no bread in the shop either? Then you have the same problem again. You have to now tell it to come back and inform you about that. This is just a simple analogy, but I think you get my point. Given a complex enough task, you can end up having a big net of various conditions and actions.

You now may end up wondering why should you bother with programming in the first place. The thing about this is that once you write a program and it works, the computer can do it any number of times with a huge efficiency so it does pay off when you need to do a specific task a substantial number of times.