Professional Documents
Culture Documents
Tassk 1
Tassk 1
Tassk 1
#include<conio.h>
using namespace std;
class employee
{
private:
string emp_id;
char emp_name[20];
float salery;
int age;
int joining_date;
char address[20];
public:
void getempdetails()
{
cout<<"\n\n\tEnter the employee id number:-";
cin>>emp_id;
cout<<"\n\n\tEnter the employee name:-";
cin>>emp_name;
cout<<"\n\n\tEnter the employee salary:-";
cin>>salery;
cout<<"\n\n\tEnter the age:-";
cin>>age;
cout<<"\n\n\tEnter the joining_date:-";
cin>>joining_date;
cout<<"\n\n\tEnter the address:-";
cin>>address;
}
void showempdata()
{
cout<<"\nEmploye details..,";
cout<<"\n\n\t the name of employe:-"<<emp_name;
cout<<"\n\n\tthe employee id number:-"<<emp_id;
cout<<"\n\n\tthe employee salery:-"<<salery;
cout<<"\n\n\tthe employee age:-"<<age;
cout<<"\n\n\tthe employee joining date:-"<<joining_date;
cout<<"\n\n\tthe employee address:="<<address;
};
int main()
{
employee e1;
e1.getempdetails();
e1.showempdata();
return 0;