Solución
solution.tsTypeScript
export function rot13(text: string): string {
let cypheredText = ''
for(let i=0; i<text.length; i++){
const charCode = text.charCodeAt(i)
if(charCode < 65 || charCode > 122 || (charCode >= 91 && charCode <= 96)){
cypheredText += String.fromCharCode(charCode)
continue
}
let base = charCode < 97 ? 65 : 97
cypheredText += String.fromCharCode((((charCode - base) + 13 )%26) + base)
}
return cypheredText
}0respuestas