#!/usr/bin/perl -w use strict; # for some value of $infile1 open (IN, "$infile1") or die "can't open $infile1"; my $linecount = 0; $hash{$line} = $linecount++ while (); close IN;