C
clearguy02
Hi folks,
I have two files, one with 1000 lines and another with 600 lines and
both files have the user login ID's and the first file has an extra of
400 user id's that I need to find.
Here is the script I have written:
------------------------------------
open (INPUT1,"fullFile.txt") or die "Cannot open the file: $!";
open (INPUT2,"comapreFile.txt") or die "Cannot open the file: $!";
@array1 = <INPUT1>;
@array2 = <INPUT2>;
foreach $word (@array2)
{
if(!grep /$word/i, @array1)
{
print "$_\n";
}
}
----------------------------------------
I am not able to see the output on the screen. Any one sees where I am
doing wrong?
Thanks
J
I have two files, one with 1000 lines and another with 600 lines and
both files have the user login ID's and the first file has an extra of
400 user id's that I need to find.
Here is the script I have written:
------------------------------------
open (INPUT1,"fullFile.txt") or die "Cannot open the file: $!";
open (INPUT2,"comapreFile.txt") or die "Cannot open the file: $!";
@array1 = <INPUT1>;
@array2 = <INPUT2>;
foreach $word (@array2)
{
if(!grep /$word/i, @array1)
{
print "$_\n";
}
}
----------------------------------------
I am not able to see the output on the screen. Any one sees where I am
doing wrong?
Thanks
J