The problem is conceptual:
If you have a list of value, you mustn't use NSDictionary. The appropriate data structure is NSArray
or NSSet
.
Basically, NSSet
is faster than NSArray
, because doesn't have to consider the order etc.
So if you need just to search a value and the order doesn't matter, the best data structure to use is NSSet
(or NSMutableSet
if you need it mutable).