String Subscript Out of Range (Line 1662).

Solved
Last edited on
length = user_input.length(); Will save lenght of entire "Hello Everyone"
istringstream(user_input) >> inputString; Will read only "Hello"
So you have 5 characters string which you think is 19 characters long. Do not store length, Do not believe what other functions returns. Calculate it in place
It works! didn't realize that I won't need to use istringstream in the function. Thanks a lot MiiNiPaa!
Last edited on
Topic archived. No new replies allowed.