lst = list(input())
for i in range(len(lst)):
k = ord(lst[i]) - 3
if k < ord('A'):
k += 26
lst[i] = chr(k)
print(''.join(lst))
lst = list(input())
for i in range(len(lst)):
k = ord(lst[i]) - 3
if k < ord('A'):
k += 26
lst[i] = chr(k)
print(''.join(lst))