Help for this page

Select Code to Download


  1. or download this
    if (exists $hash{$key}) {
      if (ref $hash{$key} and ref $hash{$key} eq 'ARRAY') {
    ...
    else {
      $hash{$key} = $letters;
    }
    
  2. or download this
      my @pushed = (ref $letters && ref $letters eq 'ARRAY') ? @$letters :
    + $letters;
      push @{$hash{$key}}, @pushed;
    
  3. or download this
    push @{$hash{$key}}, $letters;
    
  4. or download this
    for $key (keys %found_mod) {
      if (@{$found_mod{$key}} > 1) {
        print "This key -- $key -- has more than one value!\n";
      }
    }