#!/usr/bin/env perl
use strict;
use warnings;
use Test::More;
use File::Slurp;
#Counter.pl
open my $handle, '<', "/home/nic/Desktop/5-27-17/Genomes_used_HANT.txt
+";
chomp(my @HANT = <$handle>);
close $handle;
my @counts = (0,1,2,3,4,5,6,7,8,9,10);
plan tests => scalar @hant;
my $nrt2 = read_file("/home/nic/Desktop/5-27-17/NRT2.txt");
for my $hant (@HANT) {
my $matches = () = my $nrt2 =~ /$hant/g;
is ($matches, shift @counts, "Number of matches found for $hant");
}
Ok, I tried this script and got the following error. "You said to perform 0 tests at Counter.pl line 13". What should I change? Sorry like I said I am new at writing perl scripts. My script might not make sense.lol |