Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<iostream>
- using namespace std;
- class Test
- {
- private:
- int count;
- public:
- Test(): count(5){}
- void operator =()
- {count=count+1;
- }
- void display()
- {cout<<"count:"<<count;
- }
- };
- int main()
- {
- test t;
- =t;
- t.display()
- return 0;
- }
Add Comment
Please, Sign In to add comment