Help for this page

Select Code to Download


  1. or download this
    while (my ($a,$b,$c) = splice(@data, -3)) {
      push @hashrefs, { a => $a, b => $b, c => $c };
      pop @data;  # null field
    }
    
  2. or download this
    my @hashrefs;
    $#hashrefs = int(@data / 4);
    ...
      $hashrefs[$i--] = { a => $a, b => $b, c => $c };
      pop @data;
    }