# CPU: 0.05 s
print(input()[::-1])

# CPU: 0.05 s
# Pure math solution
# num = int(input())
# new_num = 0
# while num != 0:
# 	new_num *= 10
# 	new_num += num % 10
# 	num //= 10
# print(new_num)

# CPU: 0.05 s
print(input()[::-1])

# CPU: 0.05 s
# Pure math solution
# num = int(input())
# new_num = 0
# while num != 0:
# 	new_num *= 10
# 	new_num += num % 10
# 	num //= 10
# print(new_num)

# CPU: 0.05 s # CPU: 0.05 s # Pure math solution # num = int(input()) # new_num = 0 # while num != 0: # 	new_num *= 10 # 	new_num += num % 10 # 	num //= 10 # print(new_num)