- or download this
my @string;
...
}
print $string[4],$/;
- or download this
open(SYSLOG, "/tmp/log100lines") or die "Can't open file: $!\n";
...
my @string = split(/ /, $line); ## remove the function join
print "$string[4]\n";
}
- or download this
open my $fh, '<', "file_to_open" or die "can't open file: $!";
- or download this
while(<$fh>){
...
}