note
blazar
<BLOCKQUOTE><I><CODE>
sub first_line_from_file {
my $fn = shift;
open my $file, "<", $fn
or die "unable to open file $fn";
<$file>
}
</CODE></I></BLOCKQUOTE>
To return <EM>the first</EM> line I'd say
<CODE>
scalar <$file>;
</CODE>
(The semicolon is cosmetic. But I consider it good style)
464297
464306