I have a ccarray and I thought that I always had to know the initial size….
So I do this:
CCArray initwithcapacity 4
However I accidentally added 5 items to the array and the program did not crash. Does CCArray automatically resize or am I going to run into memory issues later?
You need to give an initial capacity (as you gien 4) after that if you add more element in
CCArrayit expend at runtime.it’s act same as
NSMutableArray.