<?xml version="1.0" encoding="windows-1252"?>
<node id="1002881" title="About the use of the plural form for the name of variables" created="2012-11-08 06:53:29" updated="2012-11-08 06:53:29">
<type id="115">
perlquestion</type>
<author id="946047">
grondilu</author>
<data>
<field name="doctext">
&lt;p&gt;This is a question about style.  Should I use a plural when talking about an array of things?&lt;/p&gt;

&lt;p&gt;I mean, the '@' sigil is already here to mean that I'm talking about several things.  Using an 's' at the end of the variable is kind of redondant.&lt;/p&gt;

So, what writing style would you recommend?  This one:

&lt;code&gt;
my @friend = qw(john steve carl);
for my $friend (@friend) {
    say "Hello, $friend!";
}
&lt;/code&gt;

Or this one:
&lt;code&gt;
my @friends = qw(john steve carl);
for my $friend (@friends) {
    say "Hello, $friend!";
}
&lt;/code&gt;

&lt;p&gt;??&lt;/p&gt;</field>
</data>
</node>
