Reputation: 1459
Just a quick question, when i do a for loop like this
for (NSDictionary *dic in myarray){
}
where in the array does it start, does it start from the last object, or from 0?
Thanks :D
Upvotes: 0
Views: 460
Reputation: 4600
I would do it like this:
NSDictionary *dict;
for(NSInteger i=0; i<[array count]; i++){
dict = [array objectForIndex:i];
// your stuff here
}
Upvotes: 0
Reputation: 2306
it starts from 0. in case if you need further clarifications.
Upvotes: 4