in reply to understanding curly braces surrounding an array
Actually "the" solution is changing the for loop to:
for my $alarm (@alarms) { print $alarm; }
which even your C friends will understand, although they wouldn't write it that way. Or if you don't mind that your C friends may be fazed by a little Perl you could:
print $_ for @alarms;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: understanding curly braces surrounding an array
by davido (Cardinal) on Mar 09, 2012 at 02:19 UTC | |
by GrandFather (Saint) on Mar 09, 2012 at 03:18 UTC |