In C++, I'm processing a string like follows:
using namespace std;
string parsed,input="text to be parsed";
stringstream input_stringstream(input);
if (getline(input_stringstream,parsed,' '))
{
// do some processing.
}
Parsing using a single character delimiter is acceptable.
But what if I wish to delimit using a string?
As an example, I'd want to divide:
scott>=tiger
I'll use >= as a delimiter to retrieve Scott and Tiger.