You are given a string S of length 2 or 3 consisting of lowercase English letters. If the length of the string is 2, print it as is; if the length is 3, print the string after reversing it.

Constraints:
- The length of S is 2 or 3.
- S consists of lowercase English letters.

Input:
Input is given from Standard Input in the following format:
S

Output:
If the length of S is 2, print S as is; if the length is 3, print S after reversing it.

Sample Input 1:
abc

Sample Output 1:
cba
As the length of S is 3, we print it after reversing it.

Sample Input 2:
ac

Sample Output 2:
ac
As the length of S is 2, we print it as is.

# Buggy version:
import sys

read = sys.stdin.read
readline = sys.stdin.buffer.readline
sys.setrecursionlimit(10 ** 8)
INF = float('inf')
MOD = 10 ** 9 + 7


def main():
    S = input()
    print(''.join(list(reversed(S))))


if __name__ == '__main__':
    main()


# Fixed version:
import sys

read = sys.stdin.read
readline = sys.stdin.buffer.readline
sys.setrecursionlimit(10 ** 8)
INF = float('inf')
MOD = 10 ** 9 + 7


def main():
    S = input()
    if len(S)==2:
        print(S)
    else:
        print(''.join(list(reversed(S))))


if __name__ == '__main__':
    main()

# Buggy version:
s=input()
if len(s)==2;print(s)
else:print(s[::-1])

# Fixed version:
s=input();print(s[::-1] if len(s)>2 else s)

# Buggy version:
n = input()
print n if len(n)==2 else n[::-1]

# Fixed version:
n = input()
n_len = len(n)
if n_len == 2:
    print(n)
else:
    print(n[::-1])

# Buggy version:
s = list(input())
if len(s) == 2:
    print(s)
else:
    print("".join(s[::-1]))

# Fixed version:
s = input().rstrip()
s_len = len(s)
if s_len == 2:
    print(s)
else:
    print("".join(list(s[::-1])))

# Buggy version:
a = input()
if len(a) == 2:
  print(a)
else:
  new_str = ''.join(list(reversed(a)))

# Fixed version:
a = input()
if len(a) == 2:
  print(a)
else:
  new_str = ''.join(list(reversed(a)))
  print(new_str)

# Buggy version:
if len(S) == 2:
  print(S)
if len(S) == 3:
  print(S[2]+S[1]+S[0])

# Fixed version:
S = input()
if len(S) == 3:
    S = S[2]+S[1]+S[0]
print(S)

# Buggy version:
s=list(input())
ans=''
if len(s)==2:
    print(','.join(s))
else:
    tmp=s[0]
    s[0]=s[2]
    s[2]=tmp
    print(','.join(s))

# Fixed version:
s=list(input())
ans=''
if len(s)==2:
    print(''.join(s))
else:
    tmp=s[0]
    s[0]=s[2]
    s[2]=tmp
    print(''.join(s))

# Buggy version:
###template###
import sys
input = sys.stdin.readline
def mi(): return map(int, input().split())
###template###

s = input()

if len(s)==2: print(s)
else: print(s[::-1])



# Fixed version:
###template###
#import sys
#input = sys.stdin.readline
#def mi(): return map(int, input().split())
###template###

s = input()

if len(s)==2: print(s)
else: print(s[::-1])

# Buggy version:
S=input()
if S.len()==2:print(S)
else:print(S[::-1])

# Fixed version:
S = input().rstrip()
if len(S) == 2:
    print(S)
else:
    print(S[::-1])

# Buggy version:
s = list(input())
if len(s) == 3:
    print(s[::-1].join())
else:
    print(s.join())

# Fixed version:
s = list(input())
if len(s) == 3:
    print("".join(s[::-1]))
else:
    print("".join(s))

# Buggy version:
import sys
input = sys.stdin.readline
def ii(): return int(input())
def mi(): return map(int, input().rstrip().split())
def lmi(): return list(map(int, input().rstrip().split()))
def li(): return list(input().rstrip())
# template


S = input()
if len(S) == 2:
    print(S)
else:
    list(S).reverse()
    print(''.join(S))


# Fixed version:
import sys
input = sys.stdin.readline
def ii(): return int(input())
def mi(): return map(int, input().rstrip().split())
def lmi(): return list(map(int, input().rstrip().split()))
def li(): return list(input().rstrip())
# template


S = li()
if len(S) == 2:
    print(''.join(S))
else:
    S.reverse()
    print(''.join(S))

# Buggy version:
import sys

s = sys.stdin.read().lstrip()
if len(s) % 2 == 1:
    s = s[::-1]
print(s)


# Fixed version:
import sys

s = sys.stdin.read().rstrip()
if len(s) % 2 == 1:
    s = s[::-1]
print(s)

# Buggy version:
s = input()
n = len(s)
if (n == 3):
	for i in range(n):
		print(s[n-i-1],end = "")
		print()
print(s)

# Fixed version:
s = input()
n = len(s)
if (n == 3):
	for i in range(n):
		print(s[n-i-1],end = "")
	print()
else:
	print(s)

# Buggy version:
S = input()

listed_S = list[S]
if len(listed_S)==2:
    print(S)
elif len(listed_S)==3:
    print(S[::-1])

# Fixed version:
S = input()

listed_S = list(S)
if len(listed_S)==2:
    print(S)
elif len(listed_S)==3:
    print(S[::-1])

# Buggy version:
s = input()

if ( s.__len__() == 3):
    print(s[::-1])

# Fixed version:
s = input()

if s.__len__() == 3:
    print(s[::-1])
else:
    print(s)

# Buggy version:
N=(input())
if len(N)==3:
...     N = N[::-1]
...     print(N)
... elif len(N)==2:
...     print(N)

# Fixed version:
N=input()
if len(N)==3:
     N = N[::-1]
     print(N)
elif len(N)==2:
     print(N)

# Buggy version:
a=list(input())
if len(a) == 3:
  print(str(a[::-1]))
else:
  print(str(a))


# Fixed version:
a=input()
if len(a) == 3:
    print(a[::-1])
else:
    print(str(a))

# Buggy version:
S = input()
T = ''
if len(S) == 2:
    T = S[1] + S[0]
else:
    T = S[2] + S[1] + S[0]
print(T)

# Fixed version:
S=input()
if len(S) == 2:
    print(S)
else:
    T=S[2]+S[1]+S[0]
    print(T)

# Buggy version:
s=input();print(s[::-1**len(s)])

# Fixed version:
s = input()
print(s[::(-1)**(len(s))])

# Buggy version:
str=input()
x=len(str)
if x=2:
  print(str)
else:
  print(str[::-1])

# Fixed version:
str = input()
if len(str) == 2:
  print(str)
else :
  print(str[::-1])

# Buggy version:
S = input()

if len(S) == 2:
    print(S)
elif len(S) == 3:
    str_list = list(reversed(S))
    new_str = ''.join(list(reversed(org_str)))
    print(new_str)

# Fixed version:
S = input()

if len(S) == 2:
    print(S)
elif len(S) == 3:
    #str_list = list(reversed(S))
    new_str = ''.join(list(reversed(S)))
    print(new_str)

# Buggy version:
a = list(input())

if len(a) == 2:
    print(a)
else:
    a.reverse()
    a = "".join(a)
    print(a)

# Fixed version:
a = list(input())

if len(a) == 2:
    a = "".join(a)
    print(a)
else:
    a.reverse()
    a = "".join(a)
    print(a)

# Buggy version:
#JMD
#Nagendra Jha-4096

 
import sys
import math

#import fractions
#import numpy
 
###File Operations###
fileoperation=1
if(fileoperation):
    orig_stdout = sys.stdout
    orig_stdin = sys.stdin
    inputfile = open('W:/Competitive Programming/input.txt', 'r')
    outputfile = open('W:/Competitive Programming/output.txt', 'w')
    sys.stdin = inputfile
    sys.stdout = outputfile

###Defines...###
mod=1000000007
 
###FUF's...###
def nospace(l):
    ans=''.join(str(i) for i in l)
    return ans
 
 
 
##### Main ####
s=str(input())
if(len(s)==2):
    print(s)
else:
    print(s[::-1])
    
    
#####File Operations#####
if(fileoperation):
    sys.stdout = orig_stdout
    sys.stdin = orig_stdin
    inputfile.close()
    outputfile.close()

# Fixed version:
#JMD
#Nagendra Jha-4096

 
import sys
import math

#import fractions
#import numpy
 
###File Operations###
fileoperation=0
if(fileoperation):
    orig_stdout = sys.stdout
    orig_stdin = sys.stdin
    inputfile = open('W:/Competitive Programming/input.txt', 'r')
    outputfile = open('W:/Competitive Programming/output.txt', 'w')
    sys.stdin = inputfile
    sys.stdout = outputfile

###Defines...###
mod=1000000007
 
###FUF's...###
def nospace(l):
    ans=''.join(str(i) for i in l)
    return ans
 
 
 
##### Main ####
s=str(input())
if(len(s)==2):
    print(s)
else:
    print(s[::-1])
    
    
#####File Operations#####
if(fileoperation):
    sys.stdout = orig_stdout
    sys.stdin = orig_stdin
    inputfile.close()
    outputfile.close()

# Buggy version:
s = input()
if len(s) == 2:
  print s
else :
  print s[::-1]

# Fixed version:
s = input()
length = len(s)
if length == 2:
    print(s)
else:
    print(s[::-1])

# Buggy version:
S = input()
if len(S) ==2:
    print(S)
else:
　print(S[::-1])


# Fixed version:
S = input()

if len(S) > 2:
    print(S[::-1])
else:
    print(S)

# Buggy version:
s = input()

if len(s)==2:
	print(s)
else:
	s = list(s)
	s.reverse
	print("".join(s))

# Fixed version:
s=input()
if len(s)==2:
    print(s)
else:
    s=list(s)
    s.reverse()
    print(''.join(s))

# Buggy version:
S = input()[::-1]
if len(S) == 2:
    print(S)
print(S[::-1])

# Fixed version:
S = input()
if len(S) == 2:
    print(S)
else:
    print(S[-1::-1])

# Buggy version:
if len(S)==2:
    print(S)
elif len(S)==3:
    print(S[::-1])

# Fixed version:
S = input()
if len(S) == 2:
  print(S)
elif len(S) == 3:
  print(S[::-1])

# Buggy version:
n = input()

if len(n) == 2:
    print(n)
else if len(n) == 3:
    print(n[::-1])

# Fixed version:
n = input()
if len(n) == 2:
    print(n)
else:
    print(n[::-1])

# Buggy version:
print(input() if len(input())==2 else input()[::-1])

# Fixed version:
l = input()
if len(l) == 2:
    print(l)
else:
    print(l[::-1])

# Buggy version:
s = input()
if len(S) == 2:
  print(s)
else:
  print(s[2]+s[1]+s[0])

# Fixed version:
s = input()
if(len(s) == 2):
    print(s)
else:
    print(s[2] + s[1] + s[0])

# Buggy version:
s = input()
if len(s) == 2:
    s = s[::-1]
print(s)

# Fixed version:
s=input()
if(len(s)==2):
    print(s)
else:
    print(s[::-1])

# Buggy version:
    a=input()
    if len(a)==2:
        print(a)
    else:
        print(a[::-1])

# Fixed version:
a = input()
if len(a) == 2:
	print(a)
else:
	print(a[::-1])