![]() |
|
There's more than one way to do things | |
PerlMonks |
comment on |
( #3333=superdoc: print w/replies, xml ) | Need Help?? |
This one is the best option: print Test('name 1','name 2');Even better, with a space after a comma: print Test('name 1', 'name 2');The & is not needed. It's old-fashioned and may have side effects, which aren't too interesting. The parentheses make the code more readable. Damian Conway in "Perl Best Practices" suggests always using parentheses with subroutines and no parentheses with builtins such as print, unpack etc. If you don't have the book, you may see the relevant excerpt at its Amazon page. In reply to Re: Perl Subroutines Call
by amir_e_a
|
|