How does one transliterate in perl using a negated character class? For example, I have a string abcxyz and I would like to turn it into abNNNz. I've been able to do the following: $ echo "abcxyz" | perl -plane '$_ =~ y/[abz]/N/ ' NNcxyN so I figured negating would give me the negated set, but it doesn't: $ echo "abcxyz" | perl -plane '$_ =~ y/[^abz]/N/ ' NNcxyN I know I've done this before. What am I overlooking? Regards, - RobertThread Next