in reply to Re^2: hash from sub directly into foreach loop
in thread hash from sub directly into foreach loop

You're welcome, but I did say %{ { testa() } }, not %{ { &testa } }. Your specific example code doesn't bump into the difference, but there is a difference. It's just good to be in the habit of using the subroutine() method of calling subs, instead of the Perl4-ish (and sometimes confusing) &subroutine method.

As for how to link to perlsub, see About the PerlMonks FAQ, and specifically, What shortcuts can I use for linking to other information?. ...but first read perlsub; that's a much more important step toward your understanding Perl.


Dave

Replies are listed 'Best First'.
Re^4: hash from sub directly into foreach loop
by jeanluca (Deacon) on Jun 30, 2006 at 09:05 UTC
    thnx a lot!!