I know this is simple, I just can\'t recall the best way to do this. I have an input like \" 5 15 \" that defines the x and y of a 2D vector array. I simply ne
\" 5 15 \"
Here's the stringstream way:
stringstream
int row, col; istringstream sstr(" 5 15 "); if (sstr >> row >> col) // use your valid input