Polymorphism

Polymorphism means a message or data to be processesed in more than one form.
Here ploy means"Many" and morphos means "Forms". Polymorphism can be defined  as the ability to use the same name for two or more related but technically different tasks.

Basics of C++

Introduction

The C++ Language was developed at AT&T Bell Laboratories by Bjarne Stroustrup. C++ pronounced C plus plus here “++” means the C increment operator. C++ supports the object oriented technology and C does not support object oriented language means real world entities. This is because C++ is the object oriented language. C is the structured programming language but C++ is the object oriented language.

Fixed width fields in c++

setw() is the I/O Manipulator  which is used to sets the width of the fields.

#include<iomanip.h> header file is used for manipulators.

It takes the size of the field(in number of character)as parameter.

Destructor

If a class can have a constructor to set things up, it should also have a destructor to destruct the object.A destructor is also a member function like constructor whose name is the same as the class name and can be defined like any other member function.Tilde('~') symbol is used for destruct the object. A destructor takes no arguments, no return types. A destuctor cleanup the storage(memory area of the object). The symbol('~')refers to a NOT means destructor is a Not Constructor.A constructor initializes an object and a destructor deinitializes an object.

Constructor Overloading in c++

Just like any other function, the constructor of a class may also be overloaded so that even with different
number(one argument or more)  and types(data types) of initial values, an object may still be initialized.

More Articles...

Page 6 of 7