#!/pw/prod/svr4/bin/perl use warnings; use strict; use Data::Dumper; my $ipn= qr/\( going \) there/; my $jpn="( going ) there"; if($jpn =~ m/$ipn/) { print "yes"; } else {print "nomatch";}