Hey guys I am trying to print the contents of a map container I have. I seem to be getting a nasty error from the compiler which seems to come from the pos = wordList.begin() part. any suggestions?
map<string, unsigned>::iterator pos;
for(pos = wordList.begin(); pos != wordList.end(); ++pos)
{
cout << "Key: " << pos->first << endl;
cout << "Value:" << pos->second << endl;
}
some of the error:
error: no match for âoperator=â in âpos =