你好,我是新的IOS開發,我試圖過濾我的數組我的應用程序的搜索功能。現在我得到我的代碼重複輸出這裏是我的代碼;爲什麼使用NSPredicate的數組中的過濾值返回重複輸出?
NSPredicate *myPredicate = [NSPredicate predicateWithFormat:@"self == '123456'"];
NSLog(@"adsf %@", [myMutArray filteredArrayUsingPredicate:myPredicate]);
該日誌返回一個30(123456)的值我想知道爲什麼會發生。我沒有在任何循環中運行該代碼,所以我想知道。
你是什麼意思「日誌返回30(123456)值」? – fumoboy007