Sunday, October 30, 2011

membuat satu file txt dan isinya

#include <stdio.h>
int main ()
{
  FILE * pFile; // suatu variabel yang berisi file dengan jenis.txt
  pFile = fopen ("myfile.txt","w");// w (a menulis)
  if (pFile!=NULL)
  {
    fputs ("saya sanagt ngantuk",pFile);
    fclose (pFile);
  }
  return 0;
}


0 comments:

Post a Comment

 

Copyright @ 2013 Dunia Teknologi.