#include<iostream>
using namespace std;
class anik
{
public :
int id;
double cgpa;
rob()
{
cout << "ID :: " << id << "\nCGPA :: " << cgpa << endl;
}
anik(int x, double y)
{
id = x;
cgpa = y;
}
int a, b;
anik()
{
a = 10;
b = 20;
}
};
int main()
{
anik d;
cout << "a : " << d.a << endl;
cout << "b : " << d.b << endl;
anik c(18101073, 3.59);
c.rob();
return 0;
}
using namespace std;
class anik
{
public :
int id;
double cgpa;
rob()
{
cout << "ID :: " << id << "\nCGPA :: " << cgpa << endl;
}
anik(int x, double y)
{
id = x;
cgpa = y;
}
int a, b;
anik()
{
a = 10;
b = 20;
}
};
int main()
{
anik d;
cout << "a : " << d.a << endl;
cout << "b : " << d.b << endl;
anik c(18101073, 3.59);
c.rob();
return 0;
}
Comments
Post a Comment