Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    ...
    
    printf "The colour corresponding to %d is %s\n", 1, $reverse_colours{1
    +};
    
  2. or download this
    13:32 >perl 1703_SoPW.pl
    { 1 => "blue", 2 => "green", 3 => "red", 4 => "pink", 6 => "purple" }
    The colour corresponding to 1 is blue
    
    13:32 >