最佳答案
stringstream parser;
parser << 5;
short top = 0;
parser >> top;
parser.str(""); //HERE I'M RESETTING parser
parser << 6; //DOESN'T PUT 6 INTO parser
short bottom = 0;
parser >> bottom;
Why doesn't it work?