So I am having some major issues with my object-oriented homework problem.
The problem reads:
"Write a C++ program to read the name of a text file from input and for each word in the file
output the positions where that word occurs; further, the words should appear in alphabetical order.
For example, if the file’s content is
one
two one two
three three two one
then an acceptable output is
one: 0, 2, 7
three: 4, 5
two: 1, 3, 6
You should use a map<string, list<int> > for this problem."
if someone could at the very least tell me how to use the list container within the map container that would be awesome....