programming-examples/perl/File/The eof function can be used to test if end of file has been reached.pl
2019-11-15 12:59:38 +01:00

11 lines
186 B
Perl

#Format:
#eof(FILEHANDLE)
#eof()
#eof
open ( DB, "data.txt") || die "Can't open emp.names: $!";
while(<DB>){
print if (/Norma/ .. eof); # .. is the range operator
}