in reply to Escape Quote-Like Operators

# s/(\d+)/($1 > 10)?'m':n/e; s/\d+/(m=>n)[$&<11]/e;

- tye        

Replies are listed 'Best First'.
Re^2: Escape Quote-Like Operators (fat comma)
by LanX (Saint) on Sep 12, 2013 at 10:15 UTC
    nice, but only $& and not fat comma leads to a reduction ... :)
    DB<108> $_=12;s/\d+/(m=>n)[$&<11]/e;$_ => "m" DB<109> $_=12;s/\d+/($&>10)?'m':n/e;$_ => "m"