in reply to extracting dissimilar lines

You could *very* easily do this check within this section of the code I wrote for you yesterday in this post

if ( scalar @hold > 1 ){ push @data, [ @hold ]; }

What have you tried?