Posts
 
Reputation
Joined
Last Seen
0 Reputation Points
Unknown Quality Score

No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.

0 Endorsements
Ranked #37.0K
Ranked #4K
~616 People Reached
Favorite Forums

5 Posted Topics

Member Avatar for jschri4

notice this in your code [code=C++] // inFile is a file input stream, and it havn't open a file yet, so you got the error inFile >> fileName; [/code] I guess you wanna this: [code=C++] // read user input fileName from command line cin >> fileName; [/code]

Member Avatar for Zhujy
0
92
Member Avatar for Ellisande

hey Ellisande, you said you've spent a lot of time on this, so I think I can give you a sample program. Please notice that it's not a perfect solution, you need to refine it, considering many error conditions, etc. Also, if you have any questions about the function I …

Member Avatar for Ellisande
0
134
Member Avatar for ellimist14

hi all guys I don't know if the thread have been marked solved or not (by the way, any guy can tell me how to judge that?), and maybe ellimist have fixed his problem already, I don't know, I just have a better solution [code=C++] #include <string> #include <algorithm> #include …

Member Avatar for siddhant3s
0
126
Member Avatar for walom

walom, your give the atoi function a overflow parameter. the max integer is 2147483647, which is less than "23423423423", so the result of atoi is incorrect. I give you two advices: [INDENT]1. use [B]atol[/B] instead of atoi, which turns a string to a long integer[/INDENT] [INDENT]2. refer to the [B]number_limits[/B] …

Member Avatar for siddhant3s
0
83
Member Avatar for Mossiah

Try this : [code=C++] #include <algorithm> #include <string> #include <iostream> using namespace std; int main() { string str = "abcdefg"; cout << str << endl; reverse(str.begin(), str.end()); cout << str << endl; return 0; } [/code] I think it's the simplest way to do your job.

Member Avatar for Member #46692
0
181

The End.