#include <iostream>
#include <fstream>
#include <cstdlib>

using namespace std;

int
main(int argc, char ** argv)
{
   if(argc == 2) {
      fstream fout(argv[1], ios::out | ios::in | ios::binary);
      if(fout) {
         fout.seekg(100, ios::beg);
         char ch = '\0';
         fout.read(&ch, 1);
         ch = ~ch;
         fout.seekg(100, ios::beg);
         fout.write(&ch, 1);
         fout.flush();
         fout.close();
      }
      else {
         cerr << "file " << argv[1] << " not found..." << endl;
         exit(1);
      }
   }
   else {
      cerr << "usage: " << argv[0] << " <file_to_hack>" << endl;
      exit(1);
   }
   return 0;
}

