%nc = $str =~ /?[\w\040]*)/; say %nc{status}; #### my %matches = %+; sub(\%matches);