map<string, int>::key_type v1;//v1 string
map<string, int>::value_type v2;//v2 pair<const string,int>
为何后者的key_type 是const?而 mapped_type 又不是const?
大家讲道理2017-04-17 13:00:11
Because you cannot change the key of a K/V pair that has been added to the Map, you can only change the value.
If you want to make changes to the key, you can only delete this one and add a new one.