in reply to Playing with extended chars
My recommendation is to use perl 5.8.0 or more recent and look at perldoc Encode, perldoc open, and perldoc -f open. If tr doesn't work because you have the characters encoded in two bytes, you can do
$s = decode_utf8($s);
That will convert the string into the internal representation where characters are characters and you don't have to worry about how many bytes they need for encoding.
The first attemp works like this:
perl -e '$_="áéíóú";tr/áéíóú/aeiou/;print'
BTW, encode and decode functions return values that make me think that the string is well formed, and that is tr// who's making wrong things. Am I too lost?
$s = 'holÃ¡Ã©ÃÃ³Ãºon';
$s =~ tr/Ã¡Ã©ÃÃ³Ãº/aeiou/;
# prints holaeiouon
DejaVu Sans Mono
Droid Sans Mono
Envy Code R
Source Code Pro
The default, whatever it is
Results (333 votes). Check out past polls.