and compare (left to right).$_ = '123'; if(/(1|12)(2?)/) { print "1=[$1] 2=[$2]\n"; } if(/(12|1)(2?)/) { print "1=[$1] 2=[$2]\n"; }
In reply to Re: brackets matching problem
by PodMaster
in thread brackets matching problem
by lucky8
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |