For example: I have a mutable array of BOOLs(or [NSNumber numberWithBool:TRUE]; ). and then I want to change, for example the first value in this array to FALSE.
[array addObject:[NSNumber numberWithBool:TRUE]];
[array objectAtIndex:0] ???
I know a quite strange way to do this task.
[array replaceObjectAtIndex:0 withObject:[NSNumber numberWithBool:FALSE]];
Yes, this fully satisfies me, but I am looking for another way, that is more simple than this. Something like [[array objectAtIndex:0] setBoolValue:FALSE]; for example, imagine, if I had UIButton instead of BOOLs: [[array objectAtIndex:0] setHidden:TRUE]; or this is only dreams?
Thanks in advance!