A brief introduction about what a computer is? You know! But does it really deserve to be programmed by you?
Welcome to the first Chapter of this series called Newbie Programmer. In this post, I will introduced you to the computer. Yes, you know very well. The browser you are using to read this page is working on a that. But how do we define it? Some say it is a device that calculates something. Well wasting time on social networking sites is not a calculation and if that's so, why calculators are different?
What is a Computer?
Actually It is a device that can reduces our logical works and evaluates something based on the information we provide. That's how I define it. And so a calculator becomes a tiny part of a computer.
Let us take an example of how computer reduces our logical work burdens. Suppose there is a fashion designing company. It has thousands of employees as fashion designers. Each designer has her own personal information like her name, address, family etc. And then there is her job profile like the tasks she has been given, the projects she is correctly working on, her regularity etc. And the rule of the company is that on the basis of one's family needs, her works, her regularity and achievements, her salary will be set and provided monthly.
Now Suppose you are the BOSS of these thousand employees. Sounds Cool huh? But then at the end of the month, these thousand employees will ask you for their salaries. Do you think giving them their salaries will be a simple task? You have to collect their info, rate them according to their works but think how will you do that? On papers and notebooks by hands? Then you also have to evaluate their salaries and pay them individually, even if you choose checks, would you sign a thousand times? And then suppose one day, personal info of one of the employee get changed. Now would you do it all again? And if you found there was some mistake in this whole process, how will you balance out all those big registers?
... and the solution
There comes the work of computer. All the above tasks of the boss are logical burdens but can be done by it very fast. Just program it for this work. The computer will store each employee's information and will make updates automatically if there is any change in the employee's info. It will also keep the records of the tasks of the employees. When the month ends, it will automatically evaluated their salaries on the basis of the information he has kept records of and then the money will be automatically transferred to the employees through the net banking. All the work the boss now need to do is just to approve for the money transactions. Now you can feel the Real BOSS! Just approving or declining.
That's how computer makes our life easy. But we need to program it for that purpose!
What is Programming?
Programming means teaching the computer the steps to do the work for us. For example, the Boss in the previous example will teach the following steps to the computer.
- Adding Employee's Information.
- Keeping tracks of their works.
- Evaluating their salaries according to their achievements.
- Paying them.
Each of the steps above contain many more steps inside them. For example, the 4th step:
4. Paying them:
- Making the list of the employees to be paid.
- Collecting their names and bank account details.
- Adding their salaries evaluated in the step (3) above.
- Asking bank for the transaction.
- Waiting for the Boss' Approval.
- Updating the computer that the employees have been paid for this month.
We breakdown each of our hard work into simple steps and they work collectively on computer.
Now the question of our interest comes, How to program a computer. Remember, the programming Mantra: "think simple, act like a BOSS!". So now our question changed to How to teach a computer?
How a computer is taught (or programmed)?
Well, How do we teach ourselves? We read books, or some teacher teaches us. We already know that computer can't read by itself. So some teacher has to teach it. That teacher is the Programmer. But for any type of teachings, we need a language to communicate. In case of computer, it's called the programming language. So we teach the computer using the programming language.
What do you think a computer language would look like? I mean what type of language an electronic device can understand? Is that English? Or Chinese? These are hard languages. Computer understands a very easy language, trust me.Its..
0100101001010101010010100001111 0101001110101010010101001010111 1010100110101000011111000001011
Well don't worry, When we do programming, it's in English words (not the English language) and it gets translated into zeros and ones.
For example, We write
and it get translated to some
say "Hello, World!"
010101010... (I don't know what)We get a message from the computer
That's how the computer works. This was just a basic introduction to the computer. We will learn more about the programming language in my next post. Stay connected :)
Please share this as much as you can so that we can get connected with more and more people who want to learn programming.