News for hackers. Stuff that matters.
Re:ROT13: good version by amptorn on Sunday June 09, 2019 @03:50PM (#20141460)
Just out of curiosity, what would you expect ø to encode to?
Re:ROT13: good version by dsr_ on Sunday June 09, 2019 @04:25PM (#20141679)
When I said rot13 isn't defined outside of a certain set, I meant it. If you want ø to be half-rotatable, you need to specify an ordered character set (with an even set size) and say that rot29 or rot128 or whatever you come up with is the analogous mapping to rot13.

Now, rot13 excludes punctuation and keeps capitalization after transform, so an ordinary human can learn to read rot13 English reasonably fluently. I don't know if that is common across all Latin-descended alphabetic languages, but it's really not going to be a plausible skill in Mandarin.

https://en.wikipedia.org/wiki/Chinese_characters#Indexing is somewhere between horrifying and fascinating.

On the other hand, Korean (Hangul) has a perfectly reasonable alphabetic set size and ordering, at least in South Korea. https://en.wikipedia.org/wiki/Hangul#Alphabetic_order -- so I expect that Koreans can learn to read rot12.

Re:ROT13: good version by amptorn on Sunday June 09, 2019 @06:01PM (#20142222)
> rot13 isn't defined outside of a certain set

Ah, so, when you said "øbol comes through as øoby" you were saying that this is the correct behaviour?

Re:ROT13: good version by dsr_ on Sunday June 09, 2019 @07:13PM (#20142522)
I can't say it's correct or incorrect: it's undefined, and this is one way of handling it. For some purposes it might be the best way to handle it, for others it might be bad.

Because rot13 is not defined for a lot of possible inputs, different implementations can produce different results, and not be interoperable.