L="ABCDEFGHIJKLMNOPQRSTUVWXYZ"

n=int(input())

s=input()

i=0

for j in s:

    print(s.replace(j,L[(L.index(j)+n)%26])[i],end="")

    i += 1

n=int(eval(input()))

s=eval(input())

ans=""

for c in s:

    ind = (ord(c)-ord("A")+n)%26

    ans += chr(ord("A")+ind)

print(ans)
L = "ABCDEFGHIJKLMNOPQRSTUVWXYZ"
n = int(input())
s = input()
i = 0
for j in s:
    print(s.replace(j, L[(L.index(j) + n) % 26])[i], end="")
    i += 1

n = int(eval(input()))
s = eval(input())
ans = ""
for c in s:
    ind = (ord(c) - ord("A") + n) % 26
    ans += chr(ord("A") + ind)
print(ans)

-L = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" -n = int(input()) -s = input() -i = 0 -for j in s: -    print(s.replace(j, L[(L.index(j) + n) % 26])[i], end="") -    i += 1 +n = int(eval(input())) +s = eval(input()) +ans = "" +for c in s: +    ind = (ord(c) - ord("A") + n) % 26 +    ans += chr(ord("A") + ind) +print(ans)