如何在Objective-C的字典中存储数组。我该如何修改我的代码?如何在字典中存储数组
studentDict=[[NSMutableDictionary alloc]init];
studentArray=[[NSMutableArray alloc]init];
[studentArray addObject:name.text];
[studentArray addObject:regno.text];
[studentArray addObject:marks.text];
[studentArray addObject:rank.text];
studentDict=[NSMutableDictionary dictionaryWithObjects:[NSMutableArray arrayWithObjects:studentArray, nil] forKeys:[NSMutableArray arrayWithObjects:studentArray, nil]];
NSLog(@"%@",studentArray);
'NSDictionary * studentsDictionary = @ {@“students”:studentArray};' – Zhang