Alloc: Allocates memory.
Init: Initialize.
NEW: Instead of the above two functions: Allocate memory and initialize.
Attention:
1. New is seldom used in real-world development, and we generally create objects when we are
[[ClassName Alloc]init];
2. The difference is that Alloc allocates memory when the zone is used when allocating memory to an object, the associated object is allocated to an adjacent area of memory so that it consumes very little memory at the time of the call and increases the processing speed of the program.
3. Deprecated NEW: The reason is that using new, the initialization method is fixed to use init only, and cannot invoke other INITXX methods.
4. The new method can only be initialized with the default Init method, and other custom initialization methods may be used in a alloc manner.
iOS Foundation--alloc, Init, and new methods