
sandeepsirsgi
Novice
Jan 22, 2007, 9:43 PM
Post #3 of 10
(17589 views)
|
Re: [KevinR] pattern mathc in .jar file
[In reply to]
|
Can't Post
|
|
This is the code i had . #!/usr/bin/perl use strict; use warnings; open (FILE3,"A") || die "can't open the file filename : $!\n"; open (FILE4,"B") || die "can't open the file : $!\n"; open (FILE5,">>list") || die "can't create file list : $! \n"; while(<FILE3>) { chomp; print("$_ content of file list \n"); chomp; while(my $test1 = <FILE4>) { chomp; print "$test1 \n"; if($test1 =~m /$_/) { print "Matched line is $test1 \n "; } } } close(FILE4); close(FILE3); close(FILE5); This code is printing only the first matched line from file A and B, not all. At present i have only this much of code. Any sugesstion to implement the whole requirement are welcome.
(This post was edited by sandeepsirsgi on Jan 22, 2007, 9:43 PM)
|