Help for this page

Select Code to Download


  1. or download this
    #!perl -w
    # self-contained counter script increments and prints value in DATA
    ...
    
    __DATA__
    0
    
  2. or download this
    #!perl -w
    # counter script increments and prints value in $file
    ...
    close FILE or die "$!";
    
    print $num; # print incremented value