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
~917 People Reached
Favorite Forums
Favorite Tags

3 Posted Topics

Member Avatar for johnyianni

You could write a class that is a representation of one line of your file - eg. Name, code1, code2. Then you could store a vector (see STL vector.h - an array you can keep adding to) of these classes. Each time you read a line you could create a …

Member Avatar for chrisjubb
0
222
Member Avatar for chrisjubb

I'm having problems reading or writing files in my C++ program. I'm using Fedora 16 on a USB stick and Eclipse for C/C++ developers. Here's snippet of code from my program. fp is always 0. I've also got other code that is loading files (which always fail). I've tried running …

Member Avatar for chrisjubb
0
232
Member Avatar for engineerchica

That if statement is rather hard to read. You could avoid using 'next' and 'present' and instead have a state variable that you set - eg 1st state = looking for a space, 2nd state = looking for next character. Then you could just read the next character in the …

Member Avatar for engineerchica
0
463

The End.