ex20.pp 287 B

123456789101112131415
  1. Program Example20;
  2. { Program to demonstrate the Erase function. }
  3. Var F : Text;
  4. begin
  5. { Create a file with a line of text in it}
  6. Assign (F,'test.txt');
  7. Rewrite (F);
  8. Writeln (F,'Try and find this when I''m finished !');
  9. close (f);
  10. { Now remove the file }
  11. Erase (f);
  12. end.