Hi to everyone. I'll be holding some stuff in a multimap. The problem is I want to have 2, 3 or multimaps to contain different level path. I've created a vector of these like:
vector<multimap<int, int> > paths;
Now I need to initialize the vector.
I try to do something like:
paths.push_back(new multimap<int, int>);
but I get compile errors. What is the correct way? If I resize the vector does he automatically create the objects for me? Later on what I want to do is:
getline(ifsMaze, fileline);
tmpPair.first = atoi(fileline.c_str());
tmpPair.second = atoi(fileline.substr(fileline.find(' ', 1) + 1, 10).c_str());
paths[0].insert(tmpPair);