SHARE
TWEET

Untitled

a guest Oct 17th, 2019 91 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. class Person {
  2.   int age;
  3.   char* name;
  4. public:
  5.   Person(): age(0), name(nullptr){}
  6.  
  7.   Person(const Person& other) : age(other.age), name(other.name) {}
  8.   Person& operator=(const Person& other) {
  9.     this->age = other.age;
  10.     this->name = other.name;
  11.     return *this;
  12.   }
  13.   ~Person(){}
  14. };
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top