Google+

Saturday, 18 October 2014

Algorithm: Introduction to World of Programming: Post 1

The biggest question here is, After all WHAT IS PROGRAMMING?

What is the Computer Programming?
It can be said that Computer programming is simply the act of writing computer program.



A proper program can only be written in some programming language, there are plenty of Programming language available and used in industry, Some famous and widely used once are


  • Java
  • C
  • C++
  • Python
  • PHP
  • Perl
  • Ruby
  • Java Script
So Now when we know, what programming is? The question arises, is 

What is a computer program?
It is a sequential set of instructions written using a particular programming language to perform specified task.

To make it more clear,
Let us take an example 

int a=5;
int b=6;
int c= a+b;
printf("answer to %d + %d is : %d", a,b,c);

it gives :- answer to 5 + 6 is : 11

So as you have seen, program is a simple set of instruction in a sequential form.

  • A computer program can also be said as Computer Software, which can range from two lines to millions of lines.
  • Computer program instructions are technically called program source code and programming is referred to as coding.
  • A computing machine is as useless as an empty box without proper software.
If you are able to understand this much, then you have come one step closer to becoming a programmer.

See what a programmer actually do?
  • He identifies the problem given to him (which he is required to code).
  • Designs/write a proper and well managed algorithm or pseudo code for the problem.
  • Then change the algorithm into a program according to the language. i.e. C, Java etc.

 So now, You may be wondering what is algorithm and pseudo code?
An algorithm is a step-by-step procedure to resolve any problem, It is a well defined sequential set of instruction but written in common language without any need of proper keywords.

for example let us take the problem of adding two numbers a and b.
  1. Put value of a equal to 5.
  2. Put value of b equal to 6.
  3. Add a and b, store its value in c.
  4. Print c.


A pseudo code on the other hand is an informal high-level description of the operating principle of a computer program or other algorithm.
                                                  It uses the structural convention of programming language, but is intended for easy reading rather that machine use. It typically omits details that are not essential for human understanding of algorithm. But still it is more complex and structured than algorithm and towards programming language.

example :
  1. a=5;
  2. b=6;
  3. c=a+b;
  4. print c; 


Thanks for reading the post;
Next post will be about proper programming practices:-

No comments:

Post a Comment