Everyday, we browse the internet in the search of the best bezel less monitor. We play games, we make spreadsheets, we store data, we create articles, we watch a movie. All of these activities are done in one single computer. Do you know that in order for the computer do what you want them to do, they are actually responding to a set of instructions that telling them what to do. Computers are responding to a computer program.
So what exactly is programming?
Every computer program is a series of instructions, a sequence of separate small commands, one after the other. There may be five instructions contained in a program, maybe 5,000, maybe 5,000,000, each instruction is telling the computer to do something very small but very specific. And the art of programming is to take larger idea and break it apart into these individual steps and the wonderful thing is everyone can already do this.
Let’s imagine that you’re sitting in your house in the suburbs waiting for a visit from a friend. Your phone rings!, it’s her and she’s asking for directions. She tells you that she’s at a nearby gas station and you know it, you pass it everyday, it’s on your way home. So that journey, point A to point B drops into your head as one piece, but you instantly know that you can’t communicate the journey the way you understand it.
You have to break down instructions into simpler parts. Your instructions will have to be specific, simple, clear, and self-contained instructions. Now you know that sequence here is vitally important, you mix these up and you’ll get very different results.
So with programming, we are giving directions to the computer. It’s breaking a more complex idea to the smallest possible individual task. A programming language is then used to write those instructions. If you’ve never programmed it’s not clear right now what those instructions might be. It’s probably not turn right and turn left.
What are those basic fundamental instructions you give a computer?
The instructions are often very basic. Just like driving directions, you string together enough computer instructions to get you far. Computers will do exactly what you tell them. So the instructions you give them better make sense. In programming languages, we write these instructions by writing statements.
Statements and programming languages are similar to sentences in English. Words, numbers, and punctuation are used to express one thought to form one individual piece. Depending on the programming language, the words, numbers, and punctuation may vary. For example the use of semicolon in the end, or the use of uppercase in some languages. Understanding the rule of each language is understanding the syntax of a programming language.
Programming is the ability to take this idea in your head, break it apart into its individual pieces, and know how to write those pieces depending on the programming language used at the time. Writing your statements in the right order using the right syntax.