vector<int> ParseLine (string line){
istringstream sline(line);
char c;
int n;
vector<int> row;
while(sline >> n >> c && c == ",")
row.push_back(n);
return row;
}
This is one of the functions to read 2d vector from the file. I was wondering the logic behind the while loop.