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



Sample input:
pot
top


Sample output:
YES

Submission status: Accepted

Solution code:
str1=input()
str2=input()

l1=list(str1)
l2=list(str2)

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
up=list(input())
down=list(input())
if up[0]==down[2] and up[1]==down[1] and up[2]==down[0]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
a=input()
b=input()
if a[0]==b[2] and a[1]==b[1] and a[2]==b[0]:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
import sys
sys.setrecursionlimit(10**9)
INF=10**18
MOD=10**9+7
def input(): return sys.stdin.readline().rstrip()

def main():
    A=input()
    B=input()
    C=''.join(list(reversed(B)))
    if A==C:
        print('YES')
    else:
        print('NO')

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

m1 = "".join(c1)
m2 = "".join(c2)

a1 = list(reversed(c1))
a2 = list(reversed(c2))

r1 = "".join(a2)
r2 = "".join(a1)


if r1 == m1 and r2==m2:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import sys

a = input()
b = input()

for i in range(3):
    if a[i] != b[2 - i]:
        print("NO")
        sys.exit()
print("YES")

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
l = input()
m = input()
if l[0] == m[2] and l[1] == m[1] and l[2] == m[0]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
c = [list(input()) for _ in range(2)]
print("YES" if list(reversed(c[0])) == c[1] else "NO")

Submission status: Accepted

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

if c1 == "".join(reversed(c2)):
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
# Author: cr4zjh0bp
# Created: Sat Mar 14 10:58:59 UTC 2020
import sys
 
stdin = sys.stdin
inf = 1 << 60
mod = 1000000007
 
ni = lambda: int(ns())
nin = lambda y: [ni() for _ in range(y)]
na = lambda: list(map(int, stdin.readline().split()))
nan = lambda y: [na() for _ in range(y)]
nf = lambda: float(ns())
nfn = lambda y: [nf() for _ in range(y)]
nfa = lambda: list(map(float, stdin.readline().split()))
nfan = lambda y: [nfa() for _ in range(y)]
ns = lambda: stdin.readline().rstrip()
nsn = lambda y: [ns() for _ in range(y)]
ncl = lambda y: [list(ns()) for _ in range(y)]
nas = lambda: stdin.readline().split()

c = nsn(2)

flag = True
for i in range(3):
    if c[0][i] != c[1][3 - i - 1]:
        flag = False

print("YES" if flag else "NO")

Submission status: Accepted

Solution code:
C1s = input()
C2s = input()

if C1s[::-1] == C2s:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
#abc077 a 
s=input()
t=input()
u=t[::-1]
flag=True
for i in range(3):
    if s[i]!=u[i]:
        flag=False
        break
if flag:
 	print("YES")
else:
 	print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()
T=input()
for i in range(3):
    if(S[i]!=T[2-i]):
        print('NO')
        exit()
print('YES')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
ca = input()
cb = input()

print('YES' if ca[0] == cb[2] and ca[1] == cb[1] and ca[2] == cb[0] else 'NO')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c = input()
C = input()

if c[0] == C[-1] and c[-1] == C[0]:
    if c[1] == C[1]:
        print('YES')
    else:
        print('NO')
else:
    print('NO')

Submission status: Accepted

Solution code:
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')

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
s = s[::-1]
t = input()

if s == t:
    print('YES')
else :
    print('NO')

Submission status: Accepted

Solution code:
i = list(input())
t = list(input())
e = i.pop(-1)
s = i.pop(0)
i.insert(0,e)
i.append(s)
if i == t:
  print("YES")
else:
  print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
st1=str(input())
st2=str(input())
for i in range(3):
  if st1[i]!=st2[2-i]:
    print('NO')
    break
  if i==2:
    print('YES')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

l1=input().strip()
l2=input().strip()

new_l1=l2[::-1]
new_l2=l1[::-1]

print( "YES" if l1==new_l1 and l2==new_l2 else "NO")

Submission status: Accepted

Solution code:
#077_A
C1=input()
C2=input()
print('YES' if all([C1[i]==C2[2-i] for i in range(3)]) else 'NO')

Submission status: Accepted

Solution code:
#!/usr/bin/env pypy3
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))

def main():
    s=input()
    t=input()
    f=0
    if s==t[::-1]:
        f=1
    if f==1:
        print("YES")
    else:
        print("NO")

main()

Submission status: Accepted

Solution code:
c1 = input()
c2 = input()[::-1]

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c1 = input()
c2 = input()
if list(c1) == list(reversed(c2)):
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def I(): return int(input())
def MI(): return map(int, input().split())
def LMI(): return list(map(int, input().split()))
MOD=10 ** 9 + 7


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

Submission status: Accepted

Solution code:
c = input()
d = input()
if all(c[i]==d[-1-i] for i in range(3)):
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
C=[list(input()) for i in range(2)]
if C[0]==C[1][::-1]:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
C=[list(input()) for i in range(2)]
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')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c1 = input()
c2 = input()
c2 = c2[2] + c2[1] + c2[0]

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
c1 = []
c2 = []

c1 = input()
c2 = input()

equal = 0
for i in range(3):
	if (c1[i] != c2[2-i]):
		equal = 1

if (equal == 0):
	print("YES")
else:
	print("NO")

Submission status: Accepted

Solution code:
c1 = input()
c2 = "".join(reversed(list(input())))

print("YES" if c1 ==c2 else "NO")

Submission status: Accepted

Solution code:
c1 = input()
c2 = input()
ans = "YES"
if c1[0] != c2[2]:
    ans = "NO"
elif c1[1] != c2[1]:
    ans = "NO"
elif c1[2] != c2[0]:
    ans = "NO"
print(ans)

Submission status: Accepted

Solution code:
def rotation(c , c2):

    return "YES" if c == c2[-1] + c2[1] + c2[0] else "NO"

def main():
    c = str(input())
    c2 = str(input())
    print(rotation(c , c2))

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
C1 = input()
C2 = input()
C1_r = C1[2] + C1[1] + C1[0]
print('YES' if C1_r == C2 else 'NO')

Submission status: Accepted

Solution code:
S = list(map(str, input()))
T = list(map(str, input()))

def f():
	for i in range(3):
		if S[i] != T[2 - i]:
			return "NO"
	return "YES"
	
print(f())

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
def main():
    grids = [input() for _ in range(2)]
    for i in range(3):
        if not grids[0][i] == grids[1][2 - i]:
            print("NO")
            break
    else:
        print("YES")


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
s1 = str(input())
s2 = str(input())

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c1 = list(map(str, input()))
c2 = list(map(str, input()))

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

Submission status: Accepted

Solution code:
s_a = input()
s_b = input()
if s_a[0] == s_b[2] and s_a[2] == s_b[0] and s_a[1] == s_b[1]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c = [list(input()) for _ in range(2)]
if (c[0] == c[1][::-1]) and (c[1] == c[0][::-1]):
    print('YES')
else:
    print('NO')

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=input()
b=input()
ret='YES'
for i in range(3):
  if a[i]!=b[2-i]:
    ret='NO'
    break
print(ret)

Submission status: Accepted

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

Submission status: Accepted

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

ans = "YES"

if a[0] != b[2]:
    ans = "NO"
if a[1] != b[1]:
    ans = "NO"
if a[2] != b[0]:
    ans = "NO"
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# 入力　文字列2つ、別々に
A = input()
B = input()

# 出力　AはBと逆順ならYES
if A[0] == B[2] and A[1] == B[1] and A[2] == B[0] :
    print("YES")
else :
    print("NO")

Submission status: Accepted

Solution code:
S=input()
T=input()
if [S[0],S[1],S[2]]==[T[2],T[1],T[0]]:
  print('YES')
else:
  print('NO')

Submission status: Accepted

Solution code:
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")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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')

Submission status: Accepted

Solution code:
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")

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
C = []
for i in range(2):
    c = input()
    C.append(c)

if C[0][0] == C[1][2]:
    if C[0][2] == C[1][0]:
        if C[0][1] == C[1][1]:
            print("YES")
            exit()
print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
C1=list(map(str,input()))
C2=list(map(str,input()))
CR1=C1[:]
CR2=C2[:]
C1.reverse()
C2.reverse()
print("YES" if C1==CR2 and C2==CR1 else "NO")

Submission status: Accepted

Solution code:
C1=list(map(str,input()))
C2=list(map(str,input()))
if C1[0]==C2[2] and C1[1]==C2[1] and C1[2]==C2[0]:
  print("YES")
else:
  print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a1 = input()
a2 = input()
if a1[0] == a2[2] and a1[1] == a2[1] and a1[2] == a2[0]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-


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


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
li_1 = input()
li_2 = input()
if li_1 == li_2[2]+li_2[1]+li_2[0] and li_2 == li_1[2]+li_1[1]+li_1[0]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=input()
t=input()
flag=0
if (s[0]==t[2])and(s[1]==t[1])and(s[2]==t[0]):
    flag=1
if flag==0:
    print("NO")
else:
    print("YES")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 29, Jan, 2020
"""

import sys
import itertools

# import numpy as np

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

A, B = read().decode('utf8').split()
print('YES' if A == B[::-1] and B == A[::-1] else 'NO')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

for x in range(3):
  if a[x] != b[2-x]:
    print('NO')
    exit()

print('YES')

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
A = input()
D = input()
if A[0] == D[2] and A[1] == D[1] and A[2] == D[0]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
arr = [[''] * 3 for i in range(2)]
for i in range(2):
    tmp = input()
    tmp = list(tmp)
    arr[i] = tmp

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
s = input()
s += input()

print("YES" if s == "".join(reversed(s)) else "NO")

Submission status: Accepted

Solution code:
ans = 'YES'
s = input()
t = input()
if s[0] != t[2]:
    ans = 'NO'
if s[1] != t[1]:
    ans = 'NO'
if s[2] != t[0]:
    ans = 'NO'
print(ans)

Submission status: Accepted

Solution code:
c_1 = list(input())
c_2 = list(input())

if c_1[0] == c_2[2] and c_1[1] == c_2[1] and c_1[2] == c_2[0]:
    print("YES")

else:
    print("NO")

Submission status: Accepted

Solution code:
c = [input() for _ in range(2)]

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
c = input()
c1 = input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
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")

Submission status: Accepted

Solution code:
C=input()+input()
print("YNEOS"[C!=C[::-1]::2])

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:


import numpy as np

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

Submission status: Accepted

Solution code:


import numpy as np

s=[input() for k in range(2)]
for i in range(3):
    if(s[0][i]!=s[1][2-i]):
        print("NO")
        exit(0)
print("YES")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=input()

b=input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
line1 = input()
line2 = input()

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

Submission status: Accepted

Solution code:
S1 = input().strip()
S2 = input().strip()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n1 = input()
n2 = input()

ans = ''

for i, ch in enumerate(reversed(n1)):
    ans += ch

if (n2 == ans):
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
a = list(input())
b = list(input())
b.reverse()
if a == b:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
c1 = input().strip()
c2 = input().strip()
flag = True
for i in range(3):
    if c1[i] != c2[-(i+1)]:
        flag = False
        break
if flag:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math
import queue
import bisect
import heapq
import time
import itertools

mod = int(1e9+7)

def swap(a,b):
    return (b,a)

def gcd(a,b): #最大公約数
    if (a<b):
        a,b = swap(a,b)
    if (b==0):
        return a
    else:
        return gcd(b,a%b)

def lcm(a,b): #最小公倍数
    return a/gcd(a,b)*b

def divisors(a): # 約数列挙
    divisors = []
    for i in range(1,int(a**0.5)+1):
        if a%i==0:
            divisors.append(i)
            if i!=a//i:
                divisors.append(a//i)
    return divisors

def is_prime(a): #素数判定
    if a<2:
        return False
    elif a==2:
        return True
    elif a%2==0:
        return False
    sqrt_num = int(a**0.5)
    for i in range(3,sqrt_num+1,2):
        if a%i==0:
            return False
    return True

def prime_num(a): #素数列挙
    pn = [2]
    for i in range(3,int(a**0.5),2):
        prime = True
        for j in pn:
            if i%j==0:
                prime = False
                break
        if prime:
            pn.append(i)
    return pn

def prime_fact(a): #素因数分解
    sqrt = math.sqrt(a)
    res = []
    i = 2
    if is_prime(a):
        res.append(a)
    else:
        while a!=1:
            while a%i==0:
                res.append(i)
                a //= i
            i += 1
    return res

def main():
    c1 = input()
    c2 = input()
    for i in range(3):
        if c1[i]!=c2[-1-i]:
            print('NO')
            return
    print('YES')
    return

if __name__=='__main__':
    main()

Submission status: Accepted

Solution code:
s1 = input()
s2 = input()[::-1]

if s1==s2:
  print("YES")
else:
  print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N =input()
L =input()
if (N[0]==L[2])and(N[1]==L[1])and(N[2]==L[0]):
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
C1=input()
C2=input()
print('YES' if C1==C2[2]+C2[1]+C2[0] else 'NO')

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
C1 = input()
C2 = input()
ans = 'NO'
if C1[0] == C2[2] and C1[1] == C2[1] and C1[2] == C2[0]: ans = 'YES'
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
C = []
for _ in range(2):
    C.append(list(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")

Submission status: Accepted

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

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

Submission status: Accepted

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


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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
print("YES" if list(input())==list(reversed(list(input()))) else "NO")

Submission status: Accepted

Solution code:
c = [list(str(input())) for _ in range(2)]
for i in range(3):
    if c[0][i] != c[1][-i-1]:
        print('NO')
        exit(0)
print('YES')

Submission status: Accepted

Solution code:
c = []
for i in range(2):
   c.append(input())

for i in range(3):
   if (c[0][i] != c[1][-(i+1)]):
      print('NO')
      exit()

print('YES')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = list(input())
b = list(input())
b.reverse()
print('YES' if a == b else 'NO')

Submission status: Accepted

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