3

I wondered when i put a value to it's key in two ways :

map<string, int> m;
 m["a"] = 20;

and:

m.insert(make_pair("a", 20));

what is the difference between them? Thanks.

Amr Ashraf
  • 419
  • 6
  • 19
  • 1
    There are other duplicates too. Also read [this](http://stackoverflow.com/q/326062/1870232) – P0W Aug 23 '15 at 21:03

0 Answers0