TIP: Click on subject to list as thread! ANSI
echo: aust_c_here
to: DAVID NUGENT
from: Tommy Kolega
date: 1994-05-21 22:02:00
subject: Funny Problem

From David Nugent, dated 20th May 1994 ====>

DN>Don't mix C stdio with C++ iostreams on the same file handles. They both
DN>buffer the streams independantly.  In fact, I'd recommend avoiding mixing us
DN>of both in the same program if possible - there's probably very little dange
DN>that it would cause any problem, but you're pulling in a lot of redundant
DN>library code.

DN>          while ( (c=cin.get()) !=EOF ) {
DN>             if ( isdigit(c) ) {
DN>                cin.putback(c);
DN>                end=1; // end=1 means end of ships is true!!
DN>             }
DN>             if ( !end ) {
DN>                cin.putback(c);
DN>                cin >> tempship; // overloaded cin in ship class
DN>                cout << "The details of the ship are
" << tempship;
DN>                // cout overloaded in ship class as well
DN>             .....

Thanks man, i already found this out about 2 days after i posted the
message.

I am glad somebody does listen though, i try to help people, and i
expect the same back from others

Thanks heaps again

Cheers
Tommy

 þ SLMR 2.1a þ Fire Worf......no the phasors!!!

--- EzyQwk V1.10b1



SD®¯¯*
* Origin: Lake BBS. NSW, Australia (049) 562853 (3:622/407)
SEEN-BY: 54/54 622/401 402 403 407 410 418 711/407 430 436 437 438 439 440
SEEN-BY: 711/442 446 807 808 809 932 934
@PATH: 622/407 401 711/439 430 808 809 934

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.