- open (my $F, $file) or die "cannot open file $!"; + open (my $F), '<', $file or die "cannot open file $!";