in reply to Re: More efficient way for this pattern match?
in thread More efficient way for this pattern match?

Sigh, this is too crazy. I give up, and I'll go back to golf!

This runs faster as a one-liner than as multiple lines. :(

Also tr/A-Z/\0/r is faster than tr/-/\0/cr It makes no sense :(

sub ano1 { (pop ^ pop =~ tr/A-Z/\0/r) =~ tr/\0-/-=/r =~ s/(=+(\w))/$2 +x length $1/ger =~ s/((.)=+)$/$2 x length $1/er }