// Collection of code snippets by Arne Vajhøj 
// (likely posted to comp.os.vms/INFO-VAX, INFO-TPU, MACRO32, eksperten.dk, newz.dk, LinkedIn or other place sometime between 1990 and now) 
#include <iostream>
#include <string>
#include <map>

using namespace std;

int main()
{
    map<string,int> m;
    m["a"] = 1;
    m["b"] = 2;
    m["c"] = 3;
    for(map<string,int>::iterator it=m.begin();it!=m.end();it++)
    {
        cout << it->first << " " << it->second << endl;
    }
    m.erase("b");
    for(map<string,int>::iterator it=m.begin();it!=m.end();it++)
    {
        cout << it->first << " " << it->second << endl;
    }
    return 0;
}
