vikashiiitdm has asked for the wisdom of the Perl Monks concerning the following question:
dear monks, i had been using some linux commands like grep and cat, but it seems as they doesn't take any variable except $_. this code doesn't work but when i replace it with $_ , it works. 1 more thing i had to ask is how many $_ variables can be used simultaneously and how. thanks for sharing your knowledge
foreach $keye (@key_en) { $linb=`cat /home/vikash/pro_1/en_1000 | grep --regexp '$keye'`; print "$linb\n"; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: why does it not work???
by kennethk (Abbot) on Jul 14, 2011 at 17:17 UTC |