Questions tagged [rot13]

ROT13 ("rotate 13 places") is a simple cypher in which each letter is replaced with the letter that comes 13 places after it in the alphabet.

This is a brief overview of a subject that isn't expected to come up very much. See the ROT13 Wikipedia Page for a much more detailed treatment.

When encoding a string with ROT13, A becomes N, B becomes O, and so forth. The value 13 was chosen so that the cyper is symmetric on the English alphabet; since the alphabet has 26 letters, ROT13ing twice will yield the original input. Thus the "encrypt" and "decrypt" algorithms are identical.

ROT13 is used to prevent text from being immediately readable, but still keep it available. Example applications include obscuring the punchlines of jokes, plot spoilers, and answers to puzzles.

It should never, ever be used when true security is required. Substitution cyphers can be broken with pencil and paper in a matter of minutes.

113 questions
28
votes
17 answers

Where is my implementation of rot13 in JavaScript going wrong?

Code in question with syntax highlighting here: via Friendpaste rot13.js: ERRONEOUS