ios - NSArray in NSArray addobject String -


i know how add object in single array

 [array addobject:@"lastname"]  

but have array have 2 more sub-array.i want create third sub-array , add lastname in array how can that
in advance

a litte more detailed:

nsarray *subarray1 = [nsarray arraywithobjects:@"a", @"b", @"c", nil]; nsarray *subarray2 = [nsarray arraywithobjects:@"d", @"e", @"f", nil];  nsmutablearray *mainarray = [nsmutablearray arraywithobjects:subarray1, subarray2, nil];  nsarray *subarray3 = [nsarray arraywithobjects:@"g", @"h", @"i", nil]; [mainarray addobject:subarray3]; 

good luck ;)


Comments

Popular posts from this blog

java - Custom OutputStreamAppender not run: LOGBACK: No context given for <MYAPPENDER> -

java - UML - How would you draw a try catch in a sequence diagram? -

c++ - No viable overloaded operator for references a map -