I'm a student so sorry if this is too basic of a question. I want to remove the whitespace at the start of a string, without removing the space between words.
stringstream parser(oneLine) ;
double amount ;
parser >> amount ;
string desc ;
getline(parser, desc) ;
cout << "Amount: $" << amount << " Desc: " << desc << endl ;
For example, I have this function I'm working on. It will read lines in from a text file, which are in the format of ex "10 Streaming Subscription."
The variables are currently: Amount = "10", desc =" Streaming Subscription" but I want desc to be "Streaming Subscription."