In the following subroutine, I do not understand why we need to use my ($n1,
@n2) = @_;. Why are we using @_ if it is not used elsewhere. Can somebody
throw some light on this please?

# max($n1, @n2);
# Returns the maximum of the arguments.
sub max {
my ($n1, @n2) = @_;
foreach $m (@n2) {
if ($n1 < $m) {
$n1 = $m;
}
}
return ($n1);
}

Pc



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to