سلااااااااااااام
كيف افتح ملف
1-اكتب فيه
2-اقرا منه
3-اعملupdate
#include <fstream.h>
int main()
{
ofstream f("pl.txt");
f<<"meeeeeee";
f.close();
{
ifstream openfile("pl.txt");
{
char ch;
while(!openfile.eof())
{
openfile.get(ch);
cout<<ch;
}
cout<<endl;
f.close();
}
openfile.close();
openfile.seekg(0,ios::end);
cout<<openfile.tellg();
}
openfile.seekg(0,ios::end);
cout<<openfile.tellg();
return 0;
}
__________________
