My understanding is that NSNull is an object representing a NULL value and nil is just an empty pointer.
You can fill a NSArray with NSNull objects and it'll return null values, but you can't fill it with nils.
You can do
[myNsMutableArray addObject:[NSNull null]];
but this would crash:
[myNsMutableArray addObject:nil];
Likewise:
[[NSMutableArray alloc] initWithObjects:@"1", nil, @"2", nil];
[[NSMutableArray alloc] initWithObjects:@"1", [NSNull null], @"2", nil];
The first array, when printed would output "1"
The second one would output: "1, null, 2"
So you can use NSNull to represent empty spaces in an array.
You can't insert nil into a dictionary. So checking for it means the key doesn't exist. If you check for NSNull it means that the key exists but holds an empty (NSNull) value.