#include<iostream> using namespace std; class num { private: int n; public: num(){n=1;} ~num(){} int get()const{return n;} void set(int x){n=x;} void add(){n++;} num operator++(){++n;} }; int main() { num i; cout<<"i:"<<i.get()<<endl; //i++; i.add(); cout<<"i:"<<i.get()<<endl; //++i; num n=++i; //num n=i.operator ++(); cout<<"i:"<<i.get()<<endl; return 0; }