<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">#! \usr\bin\perl

&amp;Counter;

sub Counter {

  $file='HitCount.txt';
  
if ( (! -e "$file") || (! -w "$file") )
 {
  open(NEW, "&gt;$file");
  print NEW "0";
  close(NEW);
  open(INFILE,"+&lt;$file");
 }
 else
 {
  open(INFILE,"+&lt;$file");
 }

 $num = &lt;INFILE&gt;;
 $num = $num + 1;
 seek(INFILE, 0, 0);
  print INFILE "$num\n";
  print "This page has been accessed $num times&lt;br&gt; \n";
}
</pre></body></html>