http://www.perlmonks.org?node_id=140272


in reply to Re: regular xpression stuff
in thread regular xpression stuff

shouldnt
if ( join '', sort split(//, $word) eq join '', sort split(//, $to_be_matched ) ) {
be
if ( join('', sort split(//, $word)) eq join('', sort split(//, $to_be +_matched)) ) {
(extra parenthesis added )

After adding the parenthesis , i get "Success" (i.e. "bat" = "tab" based on your example), without them the result is "Failure"