Introduction to C++
C++ is an object oriented programming language developed by Bjarne Stroustrup at Bell laboratories.
An object oriented programming language focuses mainly on classes and objects.
Class : It is a group of objects with similar properties and behaviour.
The term ' class' is used to define the class in C++. Basically, class is a template which defines the structure of the class. For example : car is a class that has a state( Model, colour, engine, gear etc.)and behaviour (changing gear, speed, applying brakes etc.)
Let us have a look at the first program in C++
#include<iostream.h>
void main()
{
cout<<"\n HELLO";
}
Classes in programming :
Keyword 'class ' is used to define a class.
It is used like a template of Abstract Data Type.
It binds the data with the functions associated with it.
It is like a blueprint of the data type.
No comments:
Post a Comment