Lennotoecom has asked for the wisdom of the Perl Monks concerning the following question:
Hi,
can you explain please
how exactly this snippet works,
and if possible context transformation:
update:
$b = @a;
would do the same effect,
so basically there is no need for ();
but still, the question remains if someone got
any explanation
update update:
thank you for answer Mr. Choroba
yes indeed that was just the wrong example that was used by some fellow
your last example was helpful
thank a lot
how exactly this snippet works,
and if possible context transformation:
Thanks!@a = qw(a b c d e); $b = () = @a; # $b now is 5
update:
$b = @a;
would do the same effect,
so basically there is no need for ();
but still, the question remains if someone got
any explanation
update update:
thank you for answer Mr. Choroba
yes indeed that was just the wrong example that was used by some fellow
your last example was helpful
thank a lot
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: need an explanation
by choroba (Cardinal) on Sep 22, 2013 at 21:55 UTC |
Back to
Seekers of Perl Wisdom