from string import ascii_uppercase as upper



n = int(eval(input()))

s = eval(input())

t = ''

for i in range(len(s)):

    t += upper[(upper.find(s[i]) + n) % 26]

print(t)
n = int(eval(input()))

s = eval(input())

t = [chr((ord(s[i])-65+n) % 26 + 65) for i in range(len(s))]

print((''.join(t)))
from string import ascii_uppercase as upper

n = int(eval(input()))
s = eval(input())
t = ""
for i in range(len(s)):
    t += upper[(upper.find(s[i]) + n) % 26]
print(t)

n = int(eval(input()))
s = eval(input())
t = [chr((ord(s[i]) - 65 + n) % 26 + 65) for i in range(len(s))]
print(("".join(t)))

-from string import ascii_uppercase as upper - -t = "" -for i in range(len(s)): -    t += upper[(upper.find(s[i]) + n) % 26] -print(t) +t = [chr((ord(s[i]) - 65 + n) % 26 + 65) for i in range(len(s))] +print(("".join(t)))