So I set up a string like this:
string input
cin >> input
then I want to split that string into a list so that all the words in between spaces are entries in a list.
So if the string were "I like cats"
The list would have the first entry be "I" and the second entry would be "like" and so on.
How do I do this??
string input
cin >> input
then I want to split that string into a list so that all the words in between spaces are entries in a list.
So if the string were "I like cats"
The list would have the first entry be "I" and the second entry would be "like" and so on.
How do I do this??
Comment