dtbach has asked for the wisdom of the Perl Monks concerning the following question:
Seeking grate Perl Monks Wisdom
Just starting to learn perl, (as evident by my code and question, but everyone has to start somewhere).
print "Enter month (Abc) \n"; my $month = <STDIN>; chomp $month; system ("mailq \| grep \@ \| \$month \|sort +6 -7");
When using $month I get no output, however if I use Oct or Nov code works fine. Using perl -c and perlcritic.com there doesn't appear to be any errors, however must be something wrong with the code. Thank you, Darryl
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Using scalar variable in system set of commands
by choroba (Cardinal) on Nov 01, 2012 at 14:37 UTC | |
by tobyink (Canon) on Nov 01, 2012 at 14:50 UTC |