Other than use plural for collections (array/hash), it is also nice if you can name the "iterator" wisely:
for my $friend (@friends) { #the relationship between $friend and @fri +ends are visually clear ... }
And
for my $person (keys(%phone_numbers)) { #$person clearly tells the mea +ning of the hash key $phone_numbers{$person}... }
In reply to Re: Perl Best Practices for naming variables
by pg
in thread Perl Best Practices for naming variables
by creamygoodness
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |