Person & Person::operator=(const Person &other){
if (this!=&other){
delete [] firstname_;
firstname_=dup(other fisrtname_);
delete [] lastname_;
lastname_=dup(other lastname_);
delete [] phone_;
phone_=dup(other phone_);
delete [] address_;
address_=dup(other address_);
}
return *this;
}
Person::Person (const Person &other):firstname_(0),
lastname_(0),
phone_(0),
address_(0) {
*this=other;
}
int main(int argc, char *argv[])
{
system("PAUSE");
return EXIT_SUCCESS;
}
i have to fill up main but i dunno how i am new for this stuff and i got error that "firstname_" is not declared
i guess one cunstructor is missing to but i dunno ; can you help with this