|
-
October 14th, 2009, 07:08 PM
#1
how to convert a string to integer with C++
Does anyone know how I could convert a string into int in C++?
I have the code ready set up but the result isn't what I expect.
example:
year = date_input.substr(second_slash, 4);
stringstream ss(year);
int in_year;
ss>> in_year;
let me know.. thanks!!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|