in reply to Re: Array size issue
in thread Array size issue

This is what I got from your reply, but still not working, this time I get nothing:

while (<$tailf>) { chomp; my $line = $_; if($line =~ m/ on $ipaddress/) { if (scalar(@matches) <= 3){ push(@matches, $line); } } last; } foreach $line (@matches){ print "$line\n"; }