title: Insert more than one pair in c++
body: <p>I have a map like this:</p>
  
  <pre><code>map&lt;string, map&lt;int, int&gt;&gt; collector;  
  </code></pre>
  
  <p>And I have no idea how to insert data in my map. If I had </p>
  
  <pre><code>map&lt;string, int&gt; collector;
  </code></pre>
  
  <p>with only key-value I would use</p>
  
  <pre><code>collector.insert(pair&lt;string, int&gt;)(name,money));
  </code></pre>
  
  <p>But what is the way of inserting when we have map in map.  I tried to do:</p>
  
  <pre><code>typedef map&lt;int, int&gt; map_;
    for(iteration = collector.begin(); iteration != collector.end(); iteration++) {
      iteration = collector.find(word);
      if(iteration == collector.end()) {
          iteration = collector.insert(map_::value_type(num,num).first;
      }
  }
  </code></pre>
  
  <p>This way is not working for me.</p>