Help for this page

Select Code to Download


  1. or download this
    sub Average {
         my @num = @_; #declare variables
         my $avg;
    ...
    
    1; # module end, must return true
    }
    
  2. or download this
    use strict;
    use warnings;
    ...
    is( High( ("a") ),       undef, "High non-number in list" );
    is( High( 0, "-1", 2 ),      2,    "High numeric string - test one" );
    is( High( 0, "-1", 2,47, 2737 ),      2737,    "High numeric string - 
    +test two" );