#!/usr/bin/perl
$txt='11:Feb:2019 "This is an Example!"';
$re1='.*?';
$re2='(e)';
$re3='.*?';
$re4='.';
$re5='.*?';
$re6='.';
$re7='.*?';
$re8='(.)';
$re=$re1.$re2.$re3.$re4.$re5.$re6.$re7.$re8;
if ($txt =~ m/$re/is)
{
$w1=$1;
$c1=$2;
print "($w1) ($c1) \n";
}
|