- or download this
sub prototyped($_;$)
{
# Here $_[0] is a compulsory argument
...
# $_[1] defaults to $_
# $_[2] may not even exist
}
- or download this
sub unprototyped
{
goto &unprototyped @_, $_ unless @_ > 1;
# See comments in previous exemples
}
- or download this
sub unprototyped
{
push @_, $_ if @_ < 2;
...
$_ = $_[-1];
# Return value here
}
- or download this
use v5.14;
sub f2
...
__DATA__
Everyone
Perlmonks