#!/usr/bin/perl
#Program name: perlread1.pl
#  display records in a file and count lines
$inpfile = $ARGV[0];
while (<>)
{
  print "$_";
  ++$line_count;
}
print ("File \"$inpfile\" has $line_count lines.\n");
