$blast = $ARGV[0];
open (BLAST, "< $blast");

while (<BLAST>) {
    ($query, $subject) = split /\t/;

    if ($query ne $previousQuery) {
        print $_;
    }
    $previousQuery = $query;
}
