#!/usr/bin/perl -w use strict; use warnings; use lib "/d/user2/aszend01/BCII/240213"; use ModuleMatching; my $locus_acc_no = ""; my $key = 1; print '$key = ', $key, "\n"; # test for not allowing more than one file to work on unless (1 == scalar(@ARGV)){ die "two many files"; } # test if the infile cannot be opened open(IN, $ARGV[0]) or die "unable to open input file $ARGV[0]\n"; while (my $line = ) { # give the number of records a new key number started with 1 incremented with 1 in each new record devided with "//" signs if ($line =~ /^\/\//){ $key++; print '$key = ', $key, "\n"; $locus_acc_no = ""; } # locus_acc_no if ($line =~ ModuleMatching::MatchLAC($locus_acc_no)) { print "locus_acc_no ", $locus_acc_no; # print $2, "\n"; # $hLocus_Acc{$key} = $1; # print "%hLocus_Acc{$key} = $1\n"; # $hLength{$key} = $2; # print "%hLength{$key} = $2\n"; } }