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:
a = input()
b = input()

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

Submission status: Accepted

Solution code:
C1, C2, C3 = input()
C4, C5, C6 = input()

if C1 == C6 and C2 == C5 and C3 == C4:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

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,b = [list(input()) for i in range(2)]
if a[0] == b[2] and a[2] == b[0] and a[1] == b[1]:
  print("YES")
else:
  print("NO")

Submission status: Accepted

Solution code:
C = [input() for _ 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=input();b=input()
print("YES" if a[::-1]==b 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:
c=[]
c.append(input())
c.append(input())
for i in range(3):
  if c[0][i]!=c[1][2-i]:
    print('NO')
    exit()
print('YES')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def same(C):
	for i in range(2):
		for j in range(3):
			if C[i][j] != C[-i-1][-j-1]:
				return False
	return True

C = []
C.append(raw_input())
C.append(raw_input())
print "YES" if same(C) else "NO"

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b = input(), input()
print('YES' if a == b[::-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:
a = list(input())
b = list(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

ans = 'YES'

for i in range(3):
    if C1[i] == C2[-i-1]:
        continue
    else:
        ans = 'NO'
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s1 = input()
s2 = input()
if s2 == s1[::-1]:
  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[0] == b[2]) and (a[1] == b[1]) and (a[2] == b[0]):
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
s,t = [input() for i in range(2)]
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[0] == C2[2] and\
    C1[1] == C2[1] and\
    C1[2] == C2[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:
a=input()
b=input()
c=b[::-1]
if a == c:
  print("YES")
else:
  print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

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:
C1 = input()
C2 = input()

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

Submission status: Accepted

Solution code:
listC = list(input())
listD = list(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
a  =  input()
b  =  input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c = []

for i in range(2):
    c.append(input())

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

else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s, s2 = input(), input()
print("YES" if s[::-1] == s2 else "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:
S = input()
T = input()

ans = "YES"

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:
M = input()
N = input()
if (M[0] == N[2] and M[2] == N[0] and M[1] == N[1]):
  print('YES')
else:
  print('NO')

Submission status: Accepted

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

Submission status: Accepted

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

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:
c1 = input()
c2 = input()

ans = 'YES'
for i in range(3):
    if c1[i] != c2[-(i+1)]:
        ans = 'NO'
        break
print(ans)

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()
b = b[::-1]
if a == b:
    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:
s1 = input()
s2 = input()

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

Submission status: Accepted

Solution code:
a=input();b=input();print("YNEOS"[a[::-1]!=b::2])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
C1=list(input())
C2=list(input())
C3=[]
for i in reversed(C2):
    C3.append(i)
print("YES" if C1==C3 else "NO")

Submission status: Accepted

Solution code:
from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursionlimit(10000)
INF = float("inf")
YES, Yes, yes, NO, No, no = "YES", "Yes", "yes", "NO", "No", "no"
dy4, dx4 = [0, 1, 0, -1], [1, 0, -1, 0]


def inside(y, x, H, W):
    return 0 <= y < H and 0 <= x < W


def ceil(a, b):
    return (a + b - 1) // b


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


if __name__ == '__main__':
    main()

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() for _ 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:
# -*- coding: utf-8 -*-

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

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
x=list(input())
y=list(input())
#print(x)
#print(y)

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

Submission status: Accepted

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

if S[2] == T[0] and S[1] == T[1] and S[0] == T[2]:
  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:
c=list(input())
b=list(input())
if "".join(c) == "".join(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:
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 = []
C.append(list(input()))
C.append(list(input()))
if C[0] == C[1][::-1]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from collections import defaultdict
import sys,heapq,bisect,math,itertools,string,queue,datetime
sys.setrecursionlimit(10**8)
INF = float('inf')
mod = 10**9+7
eps = 10**-7
def inpl(): return list(map(int, input().split()))
def inpl_s(): return list(input().split())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c = []
for i in range(2):
	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")

Submission status: Accepted

Solution code:
# cook your dish here
a=list(input())
b=list(input())
 
c = 0
if a[0] == b[2]:
    if a[1] == b[1]:
        if a[2] == b[0]:
            c = 1
if c == 0:
    print('NO')
else:
    print('YES')

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(reversed(input()))
if a == b:
    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:
c1, c2 = [input() for s in range(2)]
if c1[::-1] == c2:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
L = list(input())
R = list(input())
L_reverse = L[::-1]
R_reverse = R[::-1]
if L == R_reverse and R == L_reverse:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
l=[input() for _ in range(2)]
m=[l[1][::-1],l[0][::-1]]
if l==m:
  print("YES")
else:
  print("NO")

Submission status: Accepted

Solution code:
IN = input()
A, B, C = IN[0], IN[1], IN[2]

IN2 = input()
X, Y, Z = IN2[0], IN2[1], IN2[2]

if A==Z and B==Y and C==X:
    print("YES")
else :
    print("NO")

Submission status: Accepted

Solution code:
# utf-8:

def main():
    a = raw_input()
    b = raw_input()

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


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
C = [list(input()) for _ 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:

def main():
    a = input()
    b = input()


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

if __name__ == "__main__":
        main()

Submission status: Accepted

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

Submission status: Accepted

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

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

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

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
C = []
for i in range(2):
    C.append(input().split())
if C[0][0][::-1] == C[1][0]:
    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:
s1 = input()
s2 = input()
if s1 == s2[::-1]:
    print('YES')
else:
    print('NO')
print()

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
M = [list(input()) for _ in range(2)]
flg = True
for i in range(3):
    if M[0][i] != M[1][2 - i]:
        flg = False
        break
print('YES' if flg else 'NO')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#coding:utf-8
n1=str(input())
n2=str(input())
if(n1[0]==n2[2] and n1[2]==n2[0]):
  if(n1[1]==n2[1]):
    print("YES")
  else:
    print("NO")
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 = raw_input()
b = raw_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()
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:
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:
c_11, c_12, c_13 = input()
c_21, c_22, c_23 = input()
if c_11 == c_23 and c_12 == c_22 and c_13 == c_21:
  print('YES')
else:
  print('NO')

Submission status: Accepted

Solution code:

a=input()
d=input()

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

Submission status: Accepted

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

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:
A=list(input())
B=list(input())

B.reverse()

if A==B:
    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:
# -*- coding: utf-8 -*-

C1 = input()
C2 = input()

# 逆順にする
C1 = C1[::-1]

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

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
A=input()
B=input()

C=B[::-1]
D=A[::-1]

if A==C and B==D:
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
C = [[x for x in input()] for _ 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=input()
b=input()
if (a+b)==(a+b)[::-1]:
    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:
x=raw_input()
y=raw_input()
if x==y[::-1]:
  print 'YES'
else:
  print 'NO'

Submission status: Accepted

Solution code:
C1=input().strip()
C2=input().strip()
print("NO YES".split()[int(C1==C2[::-1])])

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:
b = list(input())
a = list(input())
if b == a[::-1]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

A = list(A)
B = list(B)

a = 0

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
print('YES' if input() == ''.join([e for e in reversed(list(input()))]) else 'NO')

Submission status: Accepted

Solution code:
l = input()
m = input()
res = 'YES'


if l[0] != m[2]:
    res = 'NO'
    
if l[1] != m[1]:
    res = 'NO'
    
if l[2] != m[0]:
    res = 'NO'
        
print(res)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c = []
for _ in range(2):
    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")

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
# input
X = input()
Y = input()

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

Submission status: Accepted

Solution code:
l = list(map(str,input()))
m = list(map(str,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:
s1 = input()
s2 = input()

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

Submission status: Accepted

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

if C[0] == C[1][::-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 = list(input())
b = list(input())
a.reverse()
if a == b:
  print("YES")
else:
  print("NO")

Submission status: Accepted

Solution code:
strlist1 = input()
strlist2 = input()

flag = True

for i in range(3):
  if strlist1[i] != strlist2[2 - i]:
    flag = False

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

Submission status: Accepted

Solution code:
upper = input()
lower = input()

if(upper[0]==lower[2] and upper[1]==lower[1] and upper[2]==lower[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 b[0] == a[2]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
a = str(input())
b = str(input())
res_b = ''

for i in reversed(b):
    res_b += i
else:
    if a == res_b:
        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:
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 -*-

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:
S=list(input())
T=list(reversed(input()))
print(["NO","YES"][S==T])

Submission status: Accepted

Solution code:
c = [input() for _ 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:
def judge(s1, s2):
	if s1[0] == s2[2] and s1[1] == s2[1] and s1[2] == s2[0]:
		return 'YES'
	else: return 'NO'

s1 = raw_input()
s2 = raw_input()

print judge(s1, s2)

Submission status: Accepted

Solution code:
a = list(input())
b = list(input())
c = a+b
d = reversed(c)

if c == list(d):
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def main():
    C11,C12,C13 = input()
    C21,C22,C23 = input()
    if C11==C23 and C21==C13 and C12==C22:
        return "YES"
    else:
        return "NO"
print(main())

Submission status: Accepted

Solution code:
C1=str(input())
C2=str(input())
C11=C1[0]
C12=C1[1]
C13=C1[2]
C21=C2[0]
C22=C2[1]
C23=C2[2]
if C11==C23 and C12==C22 and C13==C21:
    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:
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((lambda x: "YES" if x[0]==x[1][::-1] else "NO")([list(input()) for i in range(2)]))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()
T = 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:
a = input()
b = input()
print(["NO", "YES"][a[0]==b[2] and a[1]==b[1] and a[2]==b[0]])

Submission status: Accepted

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

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


if __name__ == '__main__':
    main()

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:
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 == 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:
def rotate(grid):
    return list(map(lambda x: x[::-1], grid))[::-1]


if __name__ == '__main__':
    grid = [input(), input()]
    print('YES') if grid == rotate(grid) else print('NO')

Submission status: Accepted

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

a = s[0]
b = s[1]
c = s[2]
d = t[0]
e = t[1]
f = t[2]


if a ==f and b == e and c ==d:
    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:
a = input()
b = input()

print(["NO", "YES"][a[0]==b[2] and a[2]==b[0] and a[1]==b[1]])

Submission status: Accepted

Solution code:
import sys

stdin = sys.stdin

ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
ns = lambda: stdin.readline().strip()

c1 = ns()
c2 = ns()
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:
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:
C1 = input()
C2 = input()
print("YES" if "".join(reversed(C1)) == C2 else "NO")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding: utf-8
a = input()
b = input()

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

Submission status: Accepted

Solution code:
import math
import sys

def getinputdata():

    # 配列初期化
    array_result = []
    
    data = input()

    
    array_result.append(data.split(" "))

    flg = 1

    try:


        while flg:

            data = input()

            array_temp = []

            if(data != ""):
                
                array_result.append(data.split(" "))

                flg = 1

            else:

                flg = 0
    finally:


        return array_result





arr_data = getinputdata()

s1 = arr_data[0][0]
s2 = arr_data[1][0]


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

Submission status: Accepted

Solution code:
a = input()
b = input()
c = a[::-1]
d = b[::-1]

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
up = list(input())
down = list(input())

for x in range(3):
    if up[x] == down[2-x]:
        result = "YES"
    else:
        result = "NO"
        break
print(result)

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:
upper_list = list(str(input()))
lower_list = list(str(input()))

if (upper_list[0] == lower_list[-1]) and (upper_list[1] == lower_list[1])and (upper_list[-1] == lower_list[0]):
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
c = input()
c_r = input()
c = c[::-1]
if c == c_r:
    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:
work1=input()
work2=input()

for i in range(3):
  if work1[i] != work2[2-i]:
    print('NO')
    break
  if i == 2:
    print('YES')

Submission status: Accepted

Solution code:
C = [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:
# -*- coding: utf-8 -*-

# AtCoder Beginner Contest
# Problem A

if __name__ == '__main__':
    c = [input() for _ in range(2)]

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

Submission status: Accepted

Solution code:
#-*- coding: utf-8 -*-
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:
print(['NO','YES'][input()[::-1]==input()])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
import math
import collections
import itertools
import array
import inspect

# Set max recursion limit
sys.setrecursionlimit(10000)

# Debug output
def chkprint(*args):
    names = {id(v):k for k,v in inspect.currentframe().f_back.f_locals.items()}
    print(', '.join(names.get(id(arg),'???')+' = '+repr(arg) for arg in args))

# Binary converter
def to_bin(x):
    return bin(x)[2:]

# Set 2 dimension list
def dim2input(N):
    li = []
    for _ in range(N):
        li.append(input().split())
    return li

# --------------------------------------------

dp = None

def main():
    C = []
    C.append(input())
    C.append(input())

    cond1 = C[0][0] == C[1][2]
    cond2 = C[0][1] == C[1][1]
    cond3 = C[0][2] == C[1][0]

    if cond1 and cond2 and cond3:
        print("YES")
    else:
        print("NO")

main()

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
grid = input()
reverse_grid = input()
if grid[::-1] == reverse_grid:
    print("YES")
else:
    print("NO")