We Recommend

Learning Perl Learning Perl
In this smooth, carefully paced course, a leading Perl trainer teaches you to program in the language that threatens to make C, sed, awk, and the Unix shell obsolete for many tasks. This book is the "official" guide for both formal (classroom) and informal learning. It is fully accessible to the novice programmer.


Posted By

noah on 07/03/07


Tagged

file create


Versions (?)


create new files


Published in: Perl 


  1. # whatever arguments are given at the command line are
  2. # taken to be the names for new text files,
  3. # which are then created:
  4.  
  5. open OUT, ">$ARGV[0]" or die $!;
  6. seek OUT,0,0 and print OUT "\0";
  7. close OUT;

Report this snippet 

You need to login to post a comment.