+ 3

Code explantion with map

Can somebody explain this code in super detail pls https://code.sololearn.com/cuH5Uw895NoR/?ref=app

23rd Jan 2019, 9:40 AM
Shahil Ahmed
Shahil Ahmed - avatar
1 Answer
+ 2
https://en.cppreference.com/w/cpp/container/map map<string, string> db; //declares a new map with string keys and string values db["foo"] = "bar"; //stores "bar" in db with key "foo" db.find("foo") //returns iterator to element with key equal to "foo", or end() iterator if it doesn't exist
23rd Jan 2019, 9:59 AM
Zen
Zen - avatar