// testsplit.cpp
// test the splitFirst() function
#include <iostream>
#include <cstdlib>
usingnamespace std;
// split the string into the first space-delimited token and the rest
// return the token in t and the rest as the return value
string splitFirst(string s, string &t)
{
} // splitFirst()
int main()
{
string s="There is no rest for the ones god blessed"; // Richard Thompson
string t="";
while (s.length() > 0)
{
s = splitFirst(s,t);
cout<<"First: '"<<t<<"' Remainder: '"<<s<<"'"<<endl;
}
}