sub total { my $sum = shift; $sum += $_ for @_; return $sum; }