perlquestion
hennesse
I sometimes have to do this:
<code>
$string =~ s/zero/0/ig;
$string =~ s/one/1/ig;
$string =~ s/two/2/ig;
$string =~ s/three/3/ig;
</code>
<p>
This is cool if there are just a few, but not if a lot. Is there a more compact way to do this?
</p>
<p>
i.e. I need a "trans-word-ilation" operator, similar to the "transliteration" opeerator
</p>
Thanks - Dave