63,606
社区成员




这个才是c++ - -b
#include "iostream"
using namespace std;
class Add {
private:
int a;
int b;
int c;
public:
Add() : a(0), b(0), c(0){}
Add(int av,int bv):a(av),b(bv){setC();}
void setC()
{
c= a + b;
}
int getC()
{
return (c);
}
};
int main()
{
Add* L = new Add(100,100);
cout<<L->getC()<<endl;
return 0;
}