I want to ask if there is any way to update say a text file with a content of "ooooo" to 
"ooXXo" using the fstream library. I know there is a way with cstdio but I don't want to use that one because of unsupported exception handling... Also, I don't want to read the file to memory, update the section I want and then write everything to a clean file...basically I'm looking for a way to do this with fstream:

```
/* fseek example */
#include <stdio.h>

int main ()
{
  FILE * pFile;
  pFile = fopen ( "example.txt" , "w" );
  fputs ( "This is an apple." , pFile );
  fseek ( pFile , 9 , SEEK_SET );
  fputs ( " sam" , pFile );
  fclose ( pFile );
  return 0;
}

```