#include<iostream.h>
#include<conio.h>
#include<stdio.h>
class add
{ private: int x,y,s;
public: add()
{ cout<<"enter two vallue of x,y:";
cin>>x>>y;
s =x+y;
cout<<"add="<<s;
}
};
void main()
{add a;
getch();
}
#include<conio.h>
#include<stdio.h>
class add
{ private: int x,y,s;
public: add()
{ cout<<"enter two vallue of x,y:";
cin>>x>>y;
s =x+y;
cout<<"add="<<s;
}
};
void main()
{add a;
getch();
}
No comments:
Post a Comment