Obviously though, there are much better solutions to what you actually wanted above..my $psres = `ps -xf`; my @psres=split /\n/,$psres; for (my $i = 0; $i < @psres; ++$i){ if ($psres[$i] =~ /bash/ && $psres[++$i] =~ /\s+\\_\sperl\sscriptn +ame\.pl/){ print "$1\n" if $psres[--$i] =~ /\s(\d+[^\s])/; } }
In reply to Re: patricide / matricide
by the_slycer
in thread patricide / matricide
by dshahin
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |