Tuesday, 15 October 2013

Object Orientied Programming

What is Object Oriented Programming?

In my own words, it is simply a way of classifying data. Just like in the real world, objects have specific attributes. They also have specific methods, or functions.

An example of this would be a Car. When I say car, you have a rough idea of what I am speaking about, but you don't know all the details. For example, is the car red or blue? Is it a minivan or a sports car? These details are the attributes, or characteristics of a specific object.

Objects also have methods or functions. A car wouldn't be very useful if all it did was sit there. You'd expect the car to be able to move, to be able to transport people or goods from point A to point B. What an object does can be considered its functions (known as a method in programming.)

Object oriented programming is an extremely valuable tool for all programmers. It allows you to save a large amount of time, since rather than defining every single object individually, you can define an entire group (or class) of objects which are can be used at will. 

1 comment:

  1. I really like how you explained the concept of OOP in this post.

    ReplyDelete