Last active
December 7, 2015 01:13
-
-
Save daiando/bb886c901cf73e8253ad to your computer and use it in GitHub Desktop.
write a method which takes an array of strings (containing secret enemy message bits!) and decodes its elements using ROT13 cipher system; returning an array containing the final messages.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def rot13(secret_messages) | |
secret_messages.map { |x| | |
x.tr!("A-Za-z", "N-ZA-Mn-za-m") | |
} | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment