Sunday, 27 November 2011

C++ Program For Copy A Text File Into Another Text File


#include<iostream.h>
#include<conio.h>
#include<fstream.h>
void main()
 {
   ifstream ob("d:/myfile.txt");
   ofstream ob1("d:/myfile1.txt");
   char c;
   do
    {
 ob>>c;
 ob1<<c;
}while(!ob.eof());
ob.close();
ob1.close();
 }

No comments:

Post a Comment