Does the map::find
method support case insensitive search? I have a map as follows:
map > directory;
<
No, you can not do that using find
as in that case there will be multiple matches. For example, while inserting lets you have done something like map["A"] = 1
and map["a"] = 2
and now if you want a case insensitive map.find("a")
what is the expected return value? The simplest way to solve this would be insert the string into map in only one case (either upper or lower case) and then using the same case while doing the find.