Help for this page

Select Code to Download


  1. or download this
    #! perl
    use strict;
    ...
    
    printf "The smallest value is %d, and its associated key   is %2d\n",
            $min_val, first { $h{$_} == $min_val } keys %h;
    
  2. or download this
    22:21 >perl 876_SoPW.pl
    The smallest key   is 7, and its associated value is  3
    The smallest value is 1, and its associated key   is 42
    
    22:21 >