in reply to match pattern from two different file
Alsoif # you forgot some parens here, like someone said { $line1=~ /^$pattern/; $line2=~ /^$pattern/; $line1==$line2; { print $line1; } }
my $pattern='/^LOC_Os0[1-7]g[0-9]*.[0-9]\s'; ... $line1=~ /^$pattern/; # $line1 (and 2) will expand to smth like /^^LOC_0s.../, which is prob +ably not what you want. Try my $pat = qr/^LOC_0s.../ $line1 =~ $pat;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: match pattern from two different file
by Anonymous Monk on Jun 20, 2014 at 06:45 UTC | |
by Anonymous Monk on Jun 20, 2014 at 07:24 UTC |