or download this
my @records; # Declare an array to hold records from the input file.
{ # Start a new lexical block to limit the scope
...
close IN; # Close the infile, we're done with it.
} # Close the lexical block that constrains the
# effects of the "local $/ = ....." definition.