Help for this page

Select Code to Download


  1. or download this
    foreach (@files) { 
     /(prefix)(_)(\d+)(_)(\d+)(_)(\w+)(_)(\w+)(_)(\w+)(\.)(\w+)/;
     $filename = "$1$2$3$4$5$6$7$8$9$10$11$12$13";
     print "name of file: $filename \n";
     print "\n";<c>
    
  2. or download this
    use strict;
    use warnings;
    ...
      my $filename = sprintf "S%06d.txt",$step;
      open my $tfh,'>',$filename;
    }