$somename = qr/[\w\.\s]+/; $someaddress = qr/[\w\.+]+@[\w\.]+/; if (/($somename) <($someaddress)>/) { print "Got a name of '$somename'\n"; print "Got address of '$someaddress'\n"; } #### $somename = 'David Nesting'; $someaddress = 'david@example.com'; $_ = 'David Nesting '; if (/^$somename <$someaddress>$/) { print "Yep, this one is $somename!\n"; }