User profile: jakvrh1

User info
User name:jakvrh1
History
Joined:
Number of posts:38
Latest posts:

Copy-assignment operator
I'm using pointer string because of exercise in book c++ primer. Otherwise I would use smart pointer...

Copy-assignment operator
So better way would be just to copy like this: [code] HasPtr &HasPtr::operator=(const HasPtr& obj){ ...

Copy-assignment operator
this code [code] HasPtr &HasPtr::operator=(const HasPtr& obj){ ps = new string(*obj.ps); i =...

Is c++ primer really for beginners?
The first chaper in C++ primer is bit confusing, but if you don't understand it just move to PART 1 ...

Dynamic memory
Well I know that I musn't use first code ever because it could crash program, it was just an example...