iOS开发 NSDictionary的简单遍历
-(void)dictionaryPrint
{
NSArray *keys = [dic allKeys];
id key,value;
for (int i = 0; i < [keys count]; i++) {
key = [keys objectAtIndex:i];
value = [dic objectForKey:key];
//NSLog(@"Key:%@ -- %@",key,value);
for (int j = 0; j<[value count]; j++) {
NSString *str = [value objectAtIndex:j];
NSLog(@"%@---%@",key,str);
}
}
}
更多阅读请访问http://www.hopean.com
欢迎光临小站
好岸园
http://www.hopean.com
浙公网安备 33010602011771号