in reply to Re: Re: running same bit of code twice
in thread running same bit of code twice

3-arg open is considered more secure than 2-arg open, as perl won't be looking to change it's behavior based upon any special characters (such as < > |) (update: in the filename). Since 3-arg open has no default (you can't leave the second arg undefined), you must explicitly indicate "open for read-only". Finally, some people simply like to be explicit. Why would you write
foreach my $apple (qw(McIntosh Empire Gala)){ $apple }
When this would do just fine
foreach (qw(McIntosh Empire Gala)){ $_ }

--
I'm not belgian but I play one on TV.