[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [FWP] Shortening



On Thu, Mar 08, 2001 at 09:59:53AM -0500, Keith Calvert Ivey wrote:
> I wrote:
> 
> > s/\b[c-q_]\b/\$$&/g;eval
> 
> Oops.  Make that 
> 
>   s/\b[c-qt_]\b/\$$&/g;eval
> 
> So back to 504 bytes.

I don't suppose you consider renaming the variables to improve this
approach even more?

If you renamed @a to @z and $t to $r, and remove the dollar sign from the
scalar $a, then you can do:

s/\b[a-r_]\b/\$$&/g;


Ronald

P.S.  Nevermind, I just saw from the forwarded message that the original
authors already thought of that.  :)

==== Want to unsubscribe from Fun With Perl?  Well, if you insist...
==== Send email to <fwp-request@technofile.org> with message _body_
====   unsubscribe