#String to decode rot_str = "Fraq hf gur pbqr lbh hfrq gb qrpbqr guvf zrffntr" ##Rotates string alphabet characters by 13 def rot13(rotstring) rotstring.tr 'A-Za-z', 'N-ZA-Mn-za-m' end puts rot13(rot_str)