Help for this page
open(FILE, "data.txt"); #opens data.txt in read-mode while(<FILE>){ #reads line by line from FILE which i +s the filehandle for data.txt ... print "Saw $_ in data.txt\n"; #shows you what we have read } close FILE;
use strict; ... print "Saw $_ in data.txt\n"; #shows you what we have read } close $foo; #close the file.