in reply to Little annoying mistakes ... of others
my $line = <STDIN>; chomp $line;
Can be written chomp(my $line = <STDIN>); ;D
Anyway, a pet peeve of mine would be people writing a program in Perl as if they were writing a program in C (or C++, etc). I.e., using C-style for loops when a foreach would work much better. Or, something even more annoying, putting the curlies in the same vertical column~
for (my $i = 0; $i < $#names; $i++) { print $names[$i]; }
I'm so adjective, I verb nouns!
chomp; # nom nom nom
|
---|
In Section
Meditations