tags:

views:

90

answers:

1
int k = 0;
k = [myArray  indexOfObject:_endNode];

I only have a few objects added to the array and _endNode isn't one of them.

I expect my k value to be -1. But, my k on the second line gives me a value of 21787887.

+4  A: 

It's actually NSNotFound, which is defined as NSIntegerMax.

This, by the way, is quite explicit in the documentation.

Dave DeLong
Thank you so much..:)
stone
Actually, how would I access constants from the auto complete box. Like I can see methods from NSMutableArray, by doing [NSMutableArray ...], but the constants don't show up.
stone