C++ Program Using getdata() and display()
The program uses member function getdata() and display() in-order to input student’s entry and display’s it at the end. This program contains class named ‘student’. The member function getdata() is used to take input and display() is used in-order to produce output.
Char stname, stgender;
Void getdata ()
Cout<<”\n enter the name”;
Cout<<”\n enter the gender”
Cout<<\n enter the age”;
Void display ()
Cout<<”\n name :”<<stname;
Cout<<”\n gender :”<< stgender;
Cout<,”\n age :”<< stage;
Void main ()
Obj. getdata ();
- Array of class objects Array of class objects and single inheritance A program consisting...
- Array Of Class Object Array of class objects Array is a collection of similar...
- Inheritance in C++ Inheritance in C++ Inheritance is one of the most important...
- Inline Function Inline Function The inline function is designed to speed up...
- Abstract Base Class Abstract base class It is a class which consists of...