Objectives :
- myFile_prinf_cout2.cpp
-
Introducing : int fgetpos(FILE *stream,fpos_t *pos );
pros and cons of using <cstdio> and <iostream>
FILE vs. Streaming
printf vs. cout
fgetpos( fp, &pos )
-
Inadequate buffer will put gibberish with cout
fread( buffer, sizeof( char ),21, fp );
fread( buffer, sizeof( char ),100, fp );
-
Code : myFile_prinf_cout2.txt
|