|
-
December 13th, 2006, 08:16 AM
#1
Need Help output repeating last line
Hi
I m reading a file that ends with a blank line and when i do the output it repeats the line before the blank 2 times.
I am using
ifstream infile;
infile.open ("FICHEIROS_DE_ENTRADA.TXT", ifstream::in);
while (infile.peek() != '0' && !infile.eof()){
infile>>i;
To read the input...
Can anyone help me not to repeat the last line?
Thank's
Ricardo
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
|