#!/usr/bin/perl # sub grepa { # Parms # (\@boola, \@data) # Returned value. # Array of the @data array with a cooresponding value of @boola that is true. my (@reta, $bool, $data, $index) ; ($bool, $data) = @_ ; for ($index=0; $index<=$#$data ; $index++) { push @reta, $$data[$index] if ($$bool[$index]) ; } return @reta ; } 1 ; # Needed for a require file.