On Feb 21, 2014, at 22:29 , djczaski@gmail.com wrote:I was curious how Python would handle this evil and non portable mess:$ cat io.pyfrom string import printablef = open('foo', 'w')for i in range(0, 5):f.write("hello0円world\n")f = open('foo', 'r')for l in f.readlines():print ''.join(c if c in printable else '.' for c in l),$ python io.pyhello.worldhello.worldhello.worldhello.worldhello.worldInstead of doing it right, look for others who do it worse?It's not doing it worse, it's doing exactly as you would expect. Each line is returned with the embedded '0円'. That's what you expected from Lua, no?