[Reading Notes] iOS-copying types, Reading Notes ios-copying
1. You can use different methods to copy objects. Most Objects Reference (that is, point to) other objects.
2. Copy objects in the shallow layer without copying referenced objects. The newly copied objects only point to existing referenced objects. The copy method of the NSArray class is shallow copy. When copying an NSArray object, the object you copy only copies the pointer to the referenced object, instead of the referenced object itself. If you copy an NSArray object that contains five NSString objects, you finally get five string objects available for the program, instead of ten string objects. In that case, each new object eventually obtains a pointer to a string object.
3. Deep replication copies all referenced objects. If NSArray's copy method is deep copy, you will get 10 available string objects after the copy operation is complete.
4. You can freely mix and match deep replication and shallow replication based on the needs of specific classes.
References: Objective-C Basics