As the title says, is there a dictionary similar to Objective-C’s NSDictionary for C++? I just need a data structure that holds a (key,value) pair and can be added and retrieved.
As the title says, is there a dictionary similar to Objective-C’s NSDictionary for C++?
Share
Use std::map.
For example, to map from integers to std::string: