Friday, August 13, 2010

OOP Vs Procedure oriented programming

This article is only for people who has some knowledge about computers and programming.

We keep hearing the word "Object Oriented Programming", have you ever thought of what does this mean? Most of the terms used in computer science are no different than the pure English usage of the same term.

Say, for example, what is Bit? I have seen people saying BIT -> "Binary Digit"! WTF?? How on earth can BIT be expanded to Binary Digit?? They could've as well called it as "BID" or "BD". Now take your dictionary and find out what it says? Haven't man kind used "Bit" before birth of computer??

Bit usually means something small, (usually a collection of bits forms a big thing). The entire digital domain is made of the 2 smallest positive integers 0 and 1. So, isn't it apt to call them bits of digital domain??

Now let us come back to "program", my dictionary says "a planned, coordinated group of activities, procedures, etc., often for a specific purpose, or a facility offering such a series of activities: a drug rehabilitation program; a graduate program in linguistics." Makes any sense? Is a "computer program" any different from then "program" before the era of computers?

What is "orientation"? Read it and find it yourself.

What is "Object"? During my 6th grade my physics teacher told me "object is something that occupies space" (Though not very accurate but give me a fair idea of what it is!!). The dictionary said "anything that is visible or tangible and is relatively stable inform." Not very different eh ;-) ?

So, "Object Oriented Programming" is programming that is more oriented towards object. i.e, it's orientation is towards object and not made by only objects.

"Procedure Oriented Programming" is programming that is more oriented towards procedure, i.e, it doesn't mean there are no objects in here!!

Procedures and Objects are two major building blocks of any programming. Based on the orientation (focus) of a language, it is called as "Object oriented programming" (remember this types of programming also has a lot of procedures) when its orientation is more towards objects and "Procedure oriented programming" when its orientation is more towards procedures (remember these type of language will have a lot of objects too)!

No comments: