in reply to Simplest way to match/filter 2d array of values to search in perl
Now, I define the number of string matches to be equal to '2' and threshold value to be '8'. The output should only include the rows where the no. of occurences of the value '8' is twice or more. i.e@arr = ( [ 'A' , 1, 0, 5, 6 ], [ 'B' , 3 , 4 , 5 , 6 ], [ 'C' , 2 , 4 ,3 ,5 ], [ 'D' , 6 , 7 , 8 ,8 ], [ 'E' , 2 , 5 , 4 , 5 ], [ 'F' , 4 , 8 , 8 ,8 ], [ 'G' , 1 , 2 , 4, 5 ], [ 'H' , 1 , 4 , 5, 6 ] );
Any idea on how to do this ?? Thank you very much !!!__OUTPUT__ 'D' , 6 , 7 , 8 ,8 'F' , 4 , 8 , 8 ,8
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Simplest way to match/filter 2d array of values to search in perl
by AppleFritter (Vicar) on Jul 04, 2014 at 10:22 UTC |