Algorithms/Find maximum/perl method2

perl source code

An example of using the subroutine: The output should be: 476.