Shallow copy problem


why I’m not having a problem of shallow copy?

@dhairya16,
Because you don’t have a copy constructor in your code.

but shallow copy problem occurs in default copy constructor which is hidden

@dhairya16,
I don’t think that’s true, shallow copy problem occurs when you explicitly try to make a copy constructor, and don’t pass the argument by reference.