Possible Duplicate:
(Objective-)C ints always initialized to 0?
I have an interface
@interface MyInterface
{
NSInteger _count;
}
@end
Then in my implementation I am just using is as
if (_count==0)
{
//do somthing
}
_count++;
And it works i.e. the first time around when this is executed the value is in fact 0 even though I never initialized it to be zero.
Is it because the default value of NSInteger is 0?