Hello, I am just learning perl and I have a question about return values? In the following perl script the message is printed out with or without the 'return' function why is that?
use strict; sub HowdyEveryone { my($name1, $name2) = @_; return "Hello $name1 and $name2.\n" . "Where do you want to go with Perl today?\n"; } print &HowdyEveryone("bart", "simpson");
In reply to Returning values by lblake
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |