Problem:
 Score : 100 points    Problem Statement You are given a grid with 2 rows and 3 columns of squares.
The color of the square at the i -th row and j -th column is represented by the character C_{ij} .  Write a program that prints YES if this grid remains the same when rotated 180 degrees, and prints NO otherwise.      Constraints  C_{i,j}(1 \leq i \leq 2, 1 \leq j \leq 3) is a lowercase English letter.         Input Input is given from Standard Input in the following format:  C_{11}C_{12}C_{13}  C_{21}C_{22}C_{23}       Output Print YES if this grid remains the same when rotated 180 degrees; print NO otherwise.        Sample Input 1 pot
top      Sample Output 1 YES  This grid remains the same when rotated 180 degrees.       Sample Input 2 tab
bet      Sample Output 2 NO  This grid does not remain the same when rotated 180 degrees.       Sample Input 3 eye
eel      Sample Output 3 NO

Solution (Python):
c1 = list(input())
c2 = list(input())
c1_r = [c1[2],c1[1],c1[0]]
if c1_r == c2:
    print("YES")
else:
    print("NO")

Solution (Python):
a=input()
b=input()
print('YES' if a[0]==b[2] and a[1]==b[1] and a[2]==b[0] else 'NO')

Solution (Python):
ccc1 = list(input())
ccc2 = list(input())
for i, _ in enumerate(ccc1):
    if _ != ccc2[-i-1]:
        print("NO")
        break
    if i == 2:
        print("YES")

Solution (Python):
a=input()
b=input()
print('YES' if a[0]==b[2] and a[1]==b[1] and a[2]==b[0] else 'NO')

Solution (Python):
a=input()
b=input()
print('YES' if a[0]==b[2] and a[1]==b[1] and a[2]==b[0] else 'NO')

Solution (Python):
c1 = input()
c2 = input()
print('YES' if c1[::-1] == c2 else'NO' )

Solution (Python):
a = input()
b = input()
yes = True
for i in range(len(a)):
    if a[i] != b[len(a) - 1 - i]:
        yes = False
        break
        
if yes:
    print("YES")
else:
    print("NO")

Solution (Python):
import sys

if sys.platform =='ios':
    sys.stdin=open('input_file.txt')
    

a=input()
b=input()

if a==b[::-1]:
	print("YES")
else:
	print("NO")

Solution (Python):
c_list = [input() for i in range(2)]

reversed_c_list = []
for s in reversed(c_list[0]):
    reversed_c_list.append(s)

normal_c_list = []
for s in c_list[1]:
    normal_c_list.append(s)


if reversed_c_list == normal_c_list:
    print('YES')
else:
    print('NO')

Solution (Python):
S = list(input())
T = list(input())

S.reverse()
if S==T:print('YES')
else:print('NO')

Solution (Python):
a=input()
b=input()
c=a[2]+a[1]+a[0]
if b==c:
	print("YES")
else:
	print("NO")

Solution (Python):
s0 = input().rstrip()
s1 = input().rstrip()
if s0 == s1[::-1] and s0[::-1] == s1:
    print('YES')
else:
    print('NO')

Solution (Python):

a = input()
b = input()
if ((a[0] == b[-1]) and (a[-1] == b[0]) and (a[1] == b[1])):
    print("YES")
else:
    print('NO')

Solution (Python):
A = input()
B = input()
print("YES" if A == B[::-1] else "NO")

Solution (Python):


c1 = input()
c2 = input()
c = list(c1+c2)

if c[0] == c[5] and c[1] == c[4] and c[2] == c[3]:
  print('YES')
else:
  print('NO')

Solution (Python):
x=input()
y=input()
x1=list(x)
x2=list(y)

if x1[0]==x2[2] and x1[1]==x2[1] and x1[2]==x2[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
C1 = input()
C2 = input()

if C1[0] == C2[2] and C1[1] == C2[1] and C1[2] == C2[0]:
    print('YES')
else:
    print('NO')

Solution (Python):
grid = [input() for _ in range(2)]

if grid == list(map(lambda row: row[::-1], grid))[::-1]:
    print("YES")
else:
    print("NO")

Solution (Python):
s1 = input()
s2 = input()

flag = 0
for i in range(3):
    if s1[i] != s2[2-i]:
        flag = 1
if flag == 1:
    print("NO")
else:
    print("YES")

Solution (Python):
c = [input() for i in range(2)]
print("YES" if c[0] == c[1][::-1] else "NO")

Solution (Python):
table = [list(input()) for _ in range(2)]
if table[0][0] ==table[1][2] and table[0][1] ==table[1][1] and table[0][2] == table[1][0]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()

c22 = c2[2]+c2[1]+c2[0]

if c1 == c22:
    print('YES')
else:
    print('NO')

Solution (Python):
c1 = list(input())
c2 = list(input())

if (c1[0] == c2[2]) and (c1[1] == c2[1]) and (c1[2] == c2[0]):
    print("YES")
else:
    print("NO")

Solution (Python):
s=list(input())
t=list(input())

if s[0]==t[2] and s[2]==t[0] and s[1]==t[1]:
    print('YES')
else:
    print('NO')

Solution (Python):
print("YNEOS"[input()!=input()[::-1]::2])

Solution (Python):
A,B=input(),input()
print("YES" if A[0]==B[2] and A[1]==B[1] and A[2]==B[0] else "NO")

Solution (Python):
X = input()
Y = input()
print('YES' if X[0]==Y[2] and X[1]==Y[1] and X[2]==Y[0] else 'NO')

Solution (Python):
A = input().strip()
B = input().strip()

print('YES' if A[::-1] == B else 'NO')

Solution (Python):
print('YES' if input()==input()[::-1] else 'NO')

Solution (Python):
import sys
import math
from fractions import gcd





def lcm(a, b):
    return a * b // gcd(a, b)

def combination_count(n, r):
    return math.factorial(n) // (math.factorial(n - r) * math.factorial(r))

def permutations_count(n, r):
    return math.factorial(n) // math.factorial(n - r)

big_prime = 1000000007

"""


 =  sys.stdin.readline().rstrip()
 =  list(sys.stdin.readline().rstrip())


 =  int(sys.stdin.readline())
 =  map(int, sys.stdin.readline().split())
 =  list(map(int, sys.stdin.readline().split()))
 =  [list(map(int,list(sys.stdin.readline().split()))) for i in range(N)]
"""


S1 =  sys.stdin.readline().rstrip()
S2 =  sys.stdin.readline().rstrip()

if S1[::-1] == S2:
    print("YES")
else:
    print("NO")

Solution (Python):
s1 = input()
s2 = input()
ok = True
for i in range(3):
  if s1[i] != s2[2-i]:
    ok = False
print("YES" if ok else "NO")

Solution (Python):
c1 = str(input())
c2 = str(input())

C1 = list(c1)
C2 = list(c2)

if C1[0] == C2[2] and C1[1] == C2[1] and C1[2] == C2[0]:
    print('YES')
else:
    print('NO')

Solution (Python):
print("YNEOS"[input()!=input()[::-1]::2])

Solution (Python):
s = input()
c = input()
if s[0] == c[2] and s[1] == c[1] and s[2] == c[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
a = input()
b = input()
print("YES" if a[::-1] == b else "NO")

Solution (Python):
a = input()
b = input()
if a == b[::-1]:
  print("YES")
else:
  print("NO")

Solution (Python):
c1 = input()
c2 = input()
if c1 == c2[::-1]:
  print("YES")
else:
  print("NO")

Solution (Python):
a = input()
b = input()

a = a[::-1]
if a == b:
  print("YES")
else:
  print("NO")

Solution (Python):
print('YNEOS'[input()!=input()[::-1]::2])

Solution (Python):
s1=input()
s2=input()
if s1[0]==s2[2] and s1[1]==s2[1] and s1[2]==s2[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
a = input()
b = input()
print("YES") if a[0]==b[2] and a[1]==b[1] and a[2]==b[0] else print("NO")

Solution (Python):
C1 = input()
C2 = input()

if C1 == C2[::-1]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()

if c1[0] == c2[2] and c1[1] == c2[1] and c1[2] == c2[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
a,b,c =(i for i in input())
d,e,f = (i for i in input())
if (a == f and b == e and c == d):
    print('YES')
else:
    print('NO')

Solution (Python):

C1 = list(str(input()))
C2 = list(str(input()))

if C1[0] == C2[2] and C1[1] == C2[1] and C1[2] == C2[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
a = input()
b = input()
print("YES") if a == b[::-1] else print("NO")

Solution (Python):
s1,s2 = [input() for i in range(2)]
print("YES") if s1 == s2[::-1] else print("NO")

Solution (Python):
a = list(input())
b = list(input())
copy = [a[:], b[:]]
a.reverse()
b.reverse()
c = [a,
     b]
c.reverse()
if ''.join(c[0]) == ''.join(copy[0]) and ''.join(c[1]) == ''.join(copy[1]):
    print('YES')
else:
    print('NO')

Solution (Python):
import sys
input = sys.stdin.readline

def main():
    c1 = input().strip()
    c2 = input().strip()

    if c1 == c2[::-1] and c2 == c1[::-1]:
        print("YES")
    else:
        print("NO")


if __name__ == "__main__":
    main()

Solution (Python):
a = input()
b = input()
print('YES' if a==b[::-1] else 'NO')

Solution (Python):
a = input()
b = input()
print('YES' if a==b[::-1] else 'NO')

Solution (Python):
a = input()
b = input()
if a[0]==b[2] and a[1]==b[1] and a[2]==b[0]:
	print("YES")
else: print("NO")

Solution (Python):
def resolve():
    s = input()
    t = input()
    print("YES" if s == t[::-1] else "NO")


if __name__ == "__main__":
    resolve()

Solution (Python):
C1 = input()
C2 = input()
if C1 == C2[::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
A = list(input())
B = list(input())

if A[0] == B[2] and A[1] == B[1] and A[2] == B[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = list(input())
c2 = list(input())
c1.reverse()
print('YES' if c1 == c2 else 'NO')

Solution (Python):
c1 = input()
c2 = input()

c = c1 + c2
print("YES" if c == c[::-1] else "NO")

Solution (Python):
r = input()
r += input()
g = r[::-1]
if g == r:
    print("YES")
else:
    print("NO")

Solution (Python):
s = str(input())
t = str(input())
slist = list(s)
tlist = list(t)
for item in slist:
    item.lower()
for item in tlist:
    item.lower()
judge = True
if len(slist) == len(tlist) == 3:
    for i in range(len(slist)):
        if slist[i] == tlist[2 - i]:
            continue
        else:
            judge = False
    if judge == True:
        print('YES')
    else:
        print('NO')
else:
    print('hoge!')

Solution (Python):
a = input()
b = input()

if a == b[::-1] and b == a[::-1]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()
if c1[0]==c2[2] and c1[1]==c2[1] and c1[2] == c2[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
a = input()
b = input()
print("YES" if a[0] ==b[2] and a[2] == b[0] and a[1] == b[1] else "NO")

Solution (Python):
sList = [list(input()) for _ in range(2)]
print("YES" if sList[0][2] == sList[1][0] and sList[0][1]
      == sList[1][1] and sList[0][0] == sList[1][2] else "NO")

Solution (Python):
import sys
import  math
from statistics import *
from collections import *
from operator import itemgetter
"""
from fractions import gcd
def lcm(x, y):
    return (x * y) // gcd(x, y)
"""
stdin = sys.stdin
ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
ns = lambda: stdin.readline()

a = input()
b = input()
print("YES" if a == b[::-1] else 'NO')

Solution (Python):


c1 = list(input())
c2 = list(input())

if( c1[0] == c2[2] and
    c1[1] == c2[1] and
    c1[2] == c2[0]):
    print("YES")
else:
    print("NO")

Solution (Python):
a,b = [input() for _ in range(2)]
print('YES' if a == b[::-1] else 'NO')

Solution (Python):
c1=input()
c2=input()
if c1[2]==c2[0] and c1[1]==c2[1] and c1[0]==c2[2]: print('YES')
else: print('NO')

Solution (Python):
c = list(input())
d = list(input())

if [i for i in c[::-1]] == d :
    print('YES')
else:
    print('NO')

Solution (Python):
s1 = input()
s2 = input()
if s1[::-1] == s2:
    print("YES")
else:
    print("NO")

Solution (Python):
print("YES" if input() == input()[::-1] else "NO")

Solution (Python):
a = input()
b = input()
print("YES" if a==b[::-1] and b==a[::-1] else "NO")

Solution (Python):
c = [input() for i in range(2)]
d = [c[1][::-1], c[0][::-1]]
if c == d:
    print("YES")
else:
    print("NO")

Solution (Python):
print("YES" if input()[::-1]==input() else "NO")

Solution (Python):
r1 = input()
r2 = input()
if (r1 == r2[::-1]) and (r2 == r1[::-1]):
  print("YES")
else:
  print("NO")

Solution (Python):
a,b = (input() for i in range(2))
print("YES" if a==b[::-1] else "NO")

Solution (Python):
a, b = [input() for _ in range(2)]
print('YES' if a == b[::-1] else 'NO')

Solution (Python):
a,b=open(0);print("YNEOS"[a[0]!=b[2]or a[1]!=b[1]or a[2]!=b[0]::2])

Solution (Python):
l=[input() for i in range(2)]
print("YES" if l[0][0]==l[1][2] and l[0][1]==l[1][1] and l[0][2]==l[1][0] else "NO")

Solution (Python):
list1=[]
for i in range(2):
    list1.append(list(input()))
if list1[0][0]==list1[1][2] and list1[0][1]==list1[1][1] and list1[0][2]==list1[1][0]:
    print("YES")
else:
    print("NO")

Solution (Python):
c = str(input())
c1 = str(input())
if c[1] == c1[1]:
  if c[0] == c1[2] and c[2] == c1[0]:
    print('YES')
  else:
    print('NO')
else:
  print('NO')

Solution (Python):
print('YES' if input() == input()[::-1] else 'NO')

Solution (Python):
c=input()
C=input()
if c[0]==C[2] and c[1]==C[1] and c[2]==C[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
c = input()
d = input()
roll_c = []
roll_d = []
for i in range(len(c)):
  roll_c.append(c[-(i+1)])
  roll_d.append(d[-(i+1)])
if list(c) == roll_d and list(d) == roll_c:
  print("YES")
else:
  print("NO")

Solution (Python):
a,b,c=input()
d,e,f=input()
if a==f and b==e and c==d:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()

if c1[::-1] == c2:
    print('YES')
else:
    print('NO')

Solution (Python):
c1 = input()
c2 = input()
c1 = c1[::-1]
if c1 == c2:
  print("YES")
else:
  print("NO")

Solution (Python):
a = input()
b = input()
cue = 0
for i in range(0,3):
    if a[i] == b[2-i]:
        continue
    else:
        cue = 1
        break

if cue == 0:
    print('YES')
else:
    print('NO')

Solution (Python):
Cs1 = input()
Cs2 = input()
if "".join(reversed(Cs1)) == Cs2:
  print("YES")
else:
  print("NO")

Solution (Python):
C1 = list(input())
C2 = list(input())
C2.reverse()

if C1 == C2:
	print('YES')
else:
	print('NO')

Solution (Python):
if input()==input()[::-1]:
  print("YES")
else:
  print("NO")

Solution (Python):
a = list(input())
b = list(input())

if a[0]==b[2] and a[1]==b[1] and a[2]==b[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
a=input()
b=input()
print('YES' if a[0]==b[2] and a[1]==b[1] and a[2]==b[0] else'NO')

Solution (Python):
import numpy as np
l = [list(input()) for i in range(2)]
arr = np.array(l)
if np.all(arr == np.rot90(arr,k=2)):
    print("YES")
else:
    print("NO")

Solution (Python):
a=input()
b=input()
print('YES' if a==b[::-1] else 'NO')

Solution (Python):
s1=input()
s2=input()

if s1==s2[::-1] and s2==s1[::-1]:
  print('YES')
else:
  print('NO')

Solution (Python):
print('YES'if input()==input()[::-1]else'NO')

Solution (Python):
r = str(input())
g = str(input())

if r == g[::-1]:
  print('YES')
else:
  print('NO')

Solution (Python):
N = list(map(str, [input() for i in range(2)]))
N = "".join(N)
print("YES") if N == N[::-1] else print("NO")

Solution (Python):
S1 = input()
S2 = input()
if S1[0] == S2[2] and S1[1] == S2[1] and S1[2] == S2[0]:
    print('YES')
else:
    print('NO')

Solution (Python):
r1 = input()
r2 = input()[::-1]

print("YES" if r1 == r2 else "NO")

Solution (Python):
a = input()
b = input()
print('YES' if a == b[::-1] else 'NO')

Solution (Python):
l1 = input()
l2 = input()

l1l=[c for c in l1]
l2l=[d for d in l2]
l1r=[l1l[2-i] for i in range(3)]

if l1r==l2l:
  print("YES")
else:
  print("NO")

Solution (Python):
def main():
    C = []
    for _ in range(2):
        C.append(input())
    if C[0] == C[1][::-1]:
        return "YES"
    return "NO"
if __name__ == '__main__':
    print(main())

Solution (Python):
a = input()
b = input()[::-1]
if a == b:
    print("YES")
else:
    print("NO")

Solution (Python):
a = list(input())
b = list(reversed(list(input())))
if a == b:
  print("YES")
else:
  print("NO")

Solution (Python):
s1 = input()
s2 = input()
print("YES" if s1 == s2[::-1] and s2 == s1[::-1] else "NO")

Solution (Python):
print('YES' if input() == input()[::-1] else 'NO')

Solution (Python):
a = input()
b = input()

if a[2]==b[0] and a[1]==b[1] and a[0]==b[2]:
  print("YES")
else:
  print("NO")

Solution (Python):
s1 = input()
s2 = input()

if s1[0]==s2[2] and s1[1]==s2[1] and s1[2]==s2[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
a=input()
b=input()
print("YES" if a[0]==b[-1] and a[1]==b[1] and a[-1]==b[0] else "NO")

Solution (Python):
C1=list(input())
C2=list(input())

if C1[0]==C2[2] and C1[1]==C2[1] and C1[2]==C2[0]:
    print('YES')
else :
    print('NO')

Solution (Python):
c1 = input()
c2 = input()
if c1[0]==c2[2] and c1[2]==c2[0] and c1[1]==c2[1]:
  print("YES")
else:
  print("NO")

Solution (Python):
c1 = input()
c2 = input()

if c1[0]==c2[2] and c1[1]==c2[1] and c1[2]==c2[0] and c2[0]==c1[2] and c2[2]==c1[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
a = input()
b = input()
print("YES" if a[:] == b[::-1] else "NO")

Solution (Python):
print("YES" if "".join(reversed(input())) == input() else "NO")

Solution (Python):
c1 = input()
c2 = input()
print('YES' if c1[::-1]==c2 else 'NO')

Solution (Python):
def test():
    s1 = list(input())
    s2 = list(input())
    print("YES" if s1[2]==s2[0] and s1[1]==s2[1] and s1[0]==s2[2] else "NO")


if __name__ == "__main__":
    test()

Solution (Python):
print("YES" if input()[::-1]==input() else "NO")

Solution (Python):
s = input()
t = input()
for i in range(3):
    if s[i] != t[-i-1]:
        print("NO")
        exit()
print("YES")

Solution (Python):
n1 = input()
n2 = input()
print('YES' if n1 == n2[::-1] else 'NO')

Solution (Python):
a = [i for i in input()]
b = [g for g in input()]
if a[0]==b[2] and a[1]==b[1] and a[2]==b[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
print("YES" if input() == input()[::-1] else "NO")

Solution (Python):
a = input()
b = input()
print("YES" if a == b[::-1] else"NO")

Solution (Python):
u=list(input())
b=list(input())

if((u[0]==b[2])and(u[1]==b[1])and(u[2]==b[0])):
    print("YES")
else:
    print("NO")

Solution (Python):
C1 = list(input())
C2 = list(input())
C1.reverse()
if C1 == C2:
  print('YES')
else:
  print('NO')

Solution (Python):
Ca=input()
Cb=input()
if Ca[0]==Cb[2] and Ca[1]==Cb[1] and Ca[2]==Cb[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()

if c1 == c2[::-1] and c2 == c1[::-1]:
    print("YES")
else:
    print("NO")

Solution (Python):

S1 = input()
S2 = input()

Flag=0
if S1[0]==S2[2] and S1[1]==S2[1] and S1[2]==S2[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
l1 = list(input())
l2 = list(input())

if l1[0] == l2[2] and l1[1] == l2[1] and l1[2] == l2[0]:
    print('YES')
else:
    print('NO')

Solution (Python):
c1 = input()
c2 = input()
print('YES' if c1 == c2[::-1] else 'NO')

Solution (Python):
a = input()
b = input()
print('YES' if a==b[::-1] else 'NO')

Solution (Python):
a=input()
b=input()
print("YES" if all(a[i]==b[2-i] for i in range(3)) else "NO")

Solution (Python):
c1=input()
c2=input()
print("YES" if c1 == c2[::-1] else "NO")

Solution (Python):
s=input()
t=input()
print("YES" if s==t[::-1] else "NO")

Solution (Python):
s=input()
t=input()
print("YES" if s==t[::-1] else "NO")

Solution (Python):
c1 = input()
c2 = input()
print("YES" if c1==c2[::-1] else "NO")

Solution (Python):

ue=input()
shita=input()

if ue[0]==shita[2] and ue[1]==shita[1] and ue[2]==shita[0]:
    print('YES')
else:
    print('NO')

Solution (Python):
A = input()
B = input()

print ("YES" if A == B[-1::-1] else "NO")

Solution (Python):
print('YES' if input()==input()[::-1] else 'NO')

Solution (Python):
S = open(0).read().split()
if list(S[0])==list(reversed(S[1])):
  print("YES")
else:
  print("NO")

Solution (Python):
C=[input(),input()]
res='YES'
for i in range(3):
  if C[0][i]!=C[1][2-i]: res='NO'
print(res)

Solution (Python):
s=input()
t=input()
if s==t[::-1] and t==s[::-1]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()
print('YES' if c1 == c2[::-1] else 'NO')

Solution (Python):



C1 = list(input())
C2 = list(input())


print('YES' if C1 == C2[::-1] and C2 == C1[::-1] else 'NO')

Solution (Python):
a,b=open(0).read().split()
print(['NO','YES'][a==b[::-1]])

Solution (Python):
a,b=open(0).read().split()
print(['NO','YES'][a[0]==b[2] and a[1]==b[1] and a[2]==b[0]])

Solution (Python):

a = input()
b = input()
print('YES' if a == b[::-1] else 'NO')

Solution (Python):
a, b = [input() for _ in range(2)]
print('YES' if a == b[::-1] else "NO")

Solution (Python):
s1=input()
s2=input()
ans = 0
for i in range(len(s1)):
    if s1[i] == s2[len(s1)-1-i]: ans += 1
if ans == len(s1):
    print("YES")
else:
    print("NO")

Solution (Python):
c1, c2 = [input() for _ in range(2)]
print('YES' if c1 == c2[::-1] else 'NO')

Solution (Python):
print('YNEOS'[input()!=input()[::-1]::2])

Solution (Python):
c1 = input()
c2 = input()

if c1[0] == c2[2] and c1[1] == c2[1] and c1[2] == c2[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
C1, C2 = list(input()), list(input())
C2.reverse()
print("YES" if C1 == C2 else "NO")

Solution (Python):

a = input()
b = input()
if a[0] == b[2] and a[1] == b[1] and a[2] == b[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
x=str(input())
y=str(input())
X=x[::-1]
if X==y:
    print('YES')
else:
    print('NO')

Solution (Python):
c1 = input()
c2 = input()
if c1[0] == c2[2] and c1[1] == c2[1] and c1[2] == c2[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
import numpy
a = [list(input())for _ in range(2)]
b = a.copy()
b = numpy.rot90(b, k=-2)
if (a == b).all():
    print("YES")
else:
    print("NO")

Solution (Python):
a=input()
b=input()
if a[0]==b[-1] and a[-1]==b[0] and a[1]==b[1]:
  print('YES')
else:
  print('NO')

Solution (Python):
print("YNEOS"[input()!=input()[::-1]::2])

Solution (Python):


F = input()
S = input()

if F[0]==S[2] and F[1]==S[1] and F[2]==S[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
a,b,c=input()
d,e,f=input()
if a==f and b==e and c==d :
  print("YES")
else:
  print("NO")

Solution (Python):
a = input()
b = input()

if a==b[::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
C1 = input()
C2 = input()

if C1 == C2[::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
c = list(input())
d = list(input())
if c == d[::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
a = input()
b = input()
if a[2] == b[0] and a[1] == b[1] and a[0] == b[2]:
    print("YES")
else:
    print("NO")

Solution (Python):
a = input()
b = input()
if a[::-1]==b: print('YES')
else: print('NO')

Solution (Python):
c1 = input()
c2 = input()

if c1[0]==c2[2] and c1[1]==c2[1] and c1[2]==c2[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
l1 = input()
l2= input()
if(l1[0] == l2[2] and l1[1] == l2[1] and l1[2] == l2[0]):
    print("YES")
else:
    print("NO")

Solution (Python):
print('YES' if input()==input()[::-1] else 'NO')

Solution (Python):
s1 = list(input())
s2 = list(input())
if s1[0] == s2[2] and s1[1] == s2[1] and s1[2] == s2[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
C1 = input()
C2 = input()

if C1 == C2[::-1] and C1[::-1] == C2:
    print('YES')
else:
    print('NO')

Solution (Python):
a=input()
b=input()
if a[0]==b[2] and a[1]==b[1] and a[2]==b[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
h, w = 2, 3
c = []

for _ in range(h):
    c.append(input())

if c[0][0] == c[1][2] and c[0][1] == c[1][1] and c[0][2] == c[1][0]:
    print("YES")
else:
    print("NO")

Solution (Python):
C1=input()
C2=input()

if (C1[0]==C2[2]) and (C1[2]==C2[0]) and (C1[1]==C2[1]):
  print("YES")
else:
  print("NO")

Solution (Python):
x = input()
y = input()

if x[0]==y[2] and x[1]==y[1] and x[2]==y[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
C0 = input()
C1 = input()

R0 = C0[::-1]
R1 = C1[::-1]

if C0 == R1 and C1 == R0:
  print("YES")
else:
  print("NO")

Solution (Python):
c1=input()
c2=input()
if c1[0]==c2[2] and c1[1]==c2[1] and c1[2]==c2[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
x = input()
y = input()
if x[0] == y[-1] and x[1] == y[1] and x[-1] == y[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
s = input()
t = input()
if s[0]==t[2] and s[1]==t[1] and s[2]==t[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
S = input()
T = input()

if S[0] == T[2] and S[1] == T[1] and S[2] == T[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
a = input()
b = input()[::-1]
print('YES' if a == b else 'NO')

Solution (Python):
c1=str(input())
c2=str(input())
if c1[0] == c2[2] and c1[1]==c2[1] and c1[2] == c2[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
c1 = input().rstrip()
c2 = input().rstrip()
if c1 == c2[::-1]:
  print('YES')
else:
  print('NO')

Solution (Python):

import sys
INF = float("inf")


def yes():
    print("YES")  


def no():
    print("NO")  


def main():
    s1 = input()
    s2 = input()
    if s1[0] == s2[2] and s1[1] == s2[1] and s1[2] == s2[0]:
        yes()
    else:
        no()


if __name__ == '__main__':
    main()

Solution (Python):

import sys
import copy
import collections
from bisect import bisect_left
from bisect import bisect_right
from collections import defaultdict
from heapq import heappop, heappush
import math






def inputInt(): return int(input())
def inputMap(): return map(int, input().split())
def inputList(): return list(map(int, input().split()))
 
def main():
    C1 = input()
    C2 = input()
    
    if C1[0] == C2[2] and C1[1] == C2[1] and C1[2] == C2[0]:
        print("YES")
    else:
        print("NO")
            	
if __name__ == "__main__":
	main()

Solution (Python):
one = list(input())
two = list(input())
two.reverse()
iti = "".join(one)
ni = "".join(two)
if iti == ni:
  print('YES')
else:
  print('NO')

Solution (Python):
c = [list(input()) for i in range(2)]
tmp = [[], []]
tmp[0] = c[0][:]
tmp[1] = c[1][:]
tmp[0][0], tmp[0][-1] = tmp[0][-1], tmp[0][0]
tmp[1][0], tmp[1][-1] = tmp[1][-1], tmp[1][0]
tmp[0], tmp[1] = tmp[1], tmp[0]
ans = 'YES'
for i in range(2):
    for j in range(3):
        if c[i][j] != tmp[i][j]:
            ans = 'NO'
print(ans)

Solution (Python):
a = list(input())
b = list(input())
b.reverse()

if a == b:
    print('YES')
else:
    print('NO')

Solution (Python):
if input()[::-1]==input():
  print("YES")
else:
  print("NO")

Solution (Python):


a = list(input())
b = list(input())

if a[0] == b[2] and a[1] == b[1] and a[2] == b[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
a=input()
b=input()
if a == b[::-1]:print("YES")
else:print("NO")

Solution (Python):
print(["NO","YES"][input()==input()[::-1]])

Solution (Python):
C1 = input()
C2 = input()
if C1[0] ==C2[2] and C1[1] == C2[1] and C1[2] == C2[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
s1 = input()
s2 = input()
if s1 == s2[::-1]:
  print("YES")
else:
  print("NO")

Solution (Python):
a = list(input())
b = list(input())
if a[0] == b[2] and a[1] == b[1] and a[2] == b[0]:
  print("YES")
else:
  print("NO")

Solution (Python):
a = list(input())
b = list(input())[::-1]
if a == b:
    print("YES")
else:
    print("NO")

Solution (Python):

import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from fractions import gcd

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def S_LIST(): return list(input())




sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

a = S_LIST()
b = S_LIST()


a.reverse()
if a == b:
    print("YES")
else:
    print("NO")

Solution (Python):
A = [input() for i in range(2)]
print('YES' if A[0][0] == A[1][-1] and A[0][1] == A[1][1] and A[0][2] == A[1][0] else 'NO')

Solution (Python):
C1 = [c1 for c1 in input()]
C2 = [c2 for c2 in input()]
C2.reverse()
if C1 == C2:
  print("YES")
else:
  print("NO")

Solution (Python):
a = input()
b = input()
if a[0] == b[2] and a[1] == b[1] and a[2] == b[0]:
    print("YES")
else:
    print("NO")

Solution (Python):

c1 = input()
c2 = input()
if c1[0] == c2[2] and c1[1] == c2[1] and c1[2] == c2[0]:
    print('YES')
else:
    print('NO')

Solution (Python):
s=input()
t=input()
print('YNEOS'[s[::-1]!=t::2])

Solution (Python):
c1 = input()
c2 = input()[::-1]
ans = 'NO'
if c1 == c2:
    ans = 'YES'
print(ans)

Solution (Python):
C1 = input()
C2 = input()

if (C1[0] == C2[2] and C1[1] == C2[1] and C1[2] == C2[0]) :
    print("YES")
else :
    print("NO")

Solution (Python):
c1 = list(input())
c2 = list(input())
c2.reverse()

if c1 == c2:
  print('YES')
else:
  print('NO')

Solution (Python):
C1 = input()
C2 = input()
C1 = list(C1)
C2 = list(C2)

if C1[0]==C2[2] and C1[1]==C2[1] and C1[2]==C2[0]:
    print('YES')

else:
    print('NO')

Solution (Python):
c = list(str(input()))
c.extend(list(str(input())))

if c == c[::-1]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()
if c1 == c2[::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
A = list(input())
B = list(input())
if A[0] == B[2] and A[1] == B[1] and A[2] == B[0]:
  print ('YES')
else:
  print ('NO')

Solution (Python):
a=input()
b=input()
if a[0]==b[2] and a[1]==b[1] and a[2]==b[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
C = []
C.append(input())
C.append(input())
if C[0][0] == C[1][2] and C[0][1] == C[1][1] and C[0][2] == C[1][0]:
	print('YES')
else:
	print('NO')

Solution (Python):
C1 = input()
C2 = input()

if C1[::-1] == C2:
    print('YES')
else:
    print('NO')

Solution (Python):
a = input()
b = input()

a = ''.join(list(reversed(a)))

if a == b:
    print('YES')
else:
    print('NO')

Solution (Python):
a = input()
b = input()
if a[0] == b[-1] and a[1] == b[-2] and a[2] == b[-3]:
    print("YES")
else:
    print("NO")

Solution (Python):
c1 = input()
c2 = input()

if c1[0] == c2[2] and c1[1] == c2[1] and c1[2] == c2[0]:
    print("YES")
else:
    print("NO")

Solution (Python):



x = input()
y = input()

xx = x[::-1]
yy = y[::-1]

if x == yy and y == xx:
    print('YES')
else:
    print('NO')

Solution (Python):
l_1 = input()
l_2 = input()

if l_2 == ''.join([l_1[-i-1] for i in range(len(l_1))]):
  print('YES')
else:
  print('NO')

Solution (Python):
a=input()
b=input()
if a == b[::-1]:print("YES")
else:print("NO")

Solution (Python):
s1 = input()
s2 = input()

for i in range(len(s1)):
  if s1[i] != s2[2-i]:
    print("NO")
    quit()
print("YES")

Solution (Python):
C1 = input()
C2 = input()

if C1[0] == C2[2] and C1[1] == C2[1] and C1[2] == C2[0]:
    print("YES")
else:
    print("NO")

Solution (Python):



c11, c12, c13 = list(input())
c21, c22, c23 = list(input())









if c11 == c23 and c12 == c22 and c13 == c21 and c21 == c13 and c22 == c12 and c23 == c11:
    print('YES')
else:
    print('NO')

Solution (Python):
C1=input()
C2=input()
l1=list(C1)
l2=list(C2)
if l1[0]==l2[2] and l1[1]==l2[1] and l1[2]==l2[0]:
  print('YES')
else:
  print('NO')

Solution (Python):
a=input()
b=input()
if a==b[-1::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
x = input()
y = input()
if x == y[::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
a = input()
b = input()

if a == b[::-1]:
  print("YES")
else:
  print("NO")

Solution (Python):
F = input()
S = input()

if F == S[-1::-1]:
    print('YES')
else:
    print('NO')

Solution (Python):
t = raw_input()
b = raw_input()
for i in range(3):
    if t[i] != b[-1-i]:
        print "NO"
        exit()
print "YES"

Solution (Python):
c = input()
C = input()
if c[0] == C[2] and c[1] == C[1] and c[2] == C[0]:
    print("YES")
else:
    print("NO")

Solution (Python):
from sys import stdin

a = list(input())
b = list(input())

def rot(a,b):
  if a[0] == b[2]:
    if a[1]==b[1]:
      if a[2]==b[0]:
        return 'YES'
  return 'NO'

print(rot(a,b))

Solution (Python):

from sys import stdin


def main():
    c = [0,0]
    c[0] = list(stdin.readline())
    c[1] = list(stdin.readline())
    ans = True
    for i in range(3):
        if c[0][i] != c[1][2 - i]:
            ans = False
    print(['NO', 'YES'][ans])


main()