📜  ios 遍历字典 - Python 代码示例

📅  最后修改于: 2022-03-11 14:46:02.778000             🧑  作者: Mango

代码示例1
NSDictionary *myDict = @{@"Key 1" : @"Value 1",
                         @"Key 2" : @"Value 2"}
NSEnumerator *enumerator = [myDict keyEnumerator];
id key = nil;
while((key = [enumerator nextObject]))
    NSLog(@"key=%@ value=%@", key, myDict[key]);