while True:
    try:
        str = input()
        print(str[::-1])
    except:
        break