In the code below I thought the second condition would be true, but it is turning out as false. Am I missing something? Please help me understand.
NSArray *a
NSArray is a class cluster. When you create an object of NSArray, internally it creates the object from its cluster. It adds simplicity to avoid creation of different type of objects depending upon the requirements.
For such cases you should use the function isKindOfClass
. It checks the completer hierarchy to identify the kind of object.