在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
//可变数组 NSMutableArray *ma = [NSMutableArray arrayWithCapacity:7];
[ma addObject: @"wtq"]; [ma addObject: @"wtp"]; [ma addObject: @"www"];
for (int i = 0; i<[ma count]; i++) { NSLog(@"value %@",[ma objectAtIndex:i]); }
[ma addObject:@"wwttqq"]; NSLog(@"value: %@",[ma objectAtIndex:3]);
[ma insertObject:@"insertwtq" atIndex:3];
NSLog(@"value: %@",[ma objectAtIndex:3]); NSLog(@"value: %@",[ma objectAtIndex:4]);
[ma removeObjectAtIndex:4]; NSLog(@"the length of ma is %d",[ma count]);
[ma removeObjectIdenticalTo:@"wtq"]; NSLog(@"the length of ma is %d",[ma count]); |
请发表评论