in reply to Substituting in the substitution!
#!perl -wl use strict; $_ = "[ABC AB AB12/83]"; print "I have a string like this\n$_"; s{\[([A-Z_]+)\s([A-Z_]+)\s([A-Z_]+)(\d+)/(\d+)\]}{$1_$2_$3$4_$5}; print "I would like to end up with\n$_";
perl -e"\$_=qq/nwdd\x7F^n\x7Flm{{llql0}qs\x14/;s/./chr(ord$&^30)/ge;print"
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Substituting in the substitution!
by Mondongo (Beadle) on May 06, 2004 at 16:29 UTC | |
by diotalevi (Canon) on May 06, 2004 at 17:57 UTC |