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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = input()
b = input()
if b == a[::-1] and 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:
s = input()
t = input()
print(['NO', 'YES'][int(s[::-1] == t)])

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:
# ABC077A

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

Submission status: Accepted

Solution code:
S1=input()
S2=input()
ans=1
for i in range(3):
  if S1[i]!=S2[2-i]:
    ans=ans*0
print(["NO","YES"][ans])

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
#from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
#from math import floor, ceil
#from operator import itemgetter
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
#inf = 10**17
#mod = 10**9 + 7

s=input().rstrip()
s2=input().rstrip()
if s[0]==s2[2] and s[1]==s2[1] and s[2]==s2[0]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
c1=str(input())
c2=str(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:
import numpy as np

up_ = np.array(list(reversed(input())))
lo = np.array(list(input()))

if (up_ == lo).all():
  print('YES')
else:
  print('NO')

Submission status: Accepted

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

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:
import sys
input = sys.stdin.readline

def main():
#  A,B = map(int, input().split())
  r1 = input().rstrip()
  r2 = input().rstrip()

  if r1 == r2[::-1]:
    print('YES')
  else:
    print('NO')
  
if __name__ == "__main__":
  main()

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:
text=input()
text1=input()
l=[]
for i in text:
    l.insert(0,i)
t=''
for i in l:
    t+=i
    
    

if (t==text1):
    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:
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 = list(input())
c2 = list(input())

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
t = input()
cnt = 0
if s[0] == t[2]:
    cnt += 1

if s[1] == t[1]:
    cnt += 1

if s[2] == t[0]:
    cnt += 1

if cnt == 3:
    print("YES")
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:
import sys,collections as cl,bisect as bs
sys.setrecursionlimit(100000)
input = sys.stdin.readline
mod = 10**9+7
Max = sys.maxsize
def l(): #intのlist
    return list(map(int,input().split()))
def m(): #複数文字
    return map(int,input().split())
def onem(): #Nとかの取得
    return int(input())
def s(x): #圧縮
    a = []
    if len(x) == 0:
        return []
    aa = x[0]
    su = 1
    for i in range(len(x)-1):
        if aa != x[i+1]:
            a.append([aa,su])
            aa = x[i+1]
            su = 1
        else:
            su += 1
    a.append([aa,su])
    return a
def jo(x): #listをスペースごとに分ける
    return " ".join(map(str,x))
def max2(x): #他のときもどうように作成可能
    return max(map(max,x))
def In(x,a): #aがリスト(sorted)
    k = bs.bisect_left(a,x)
    if k != len(a) and a[k] ==  x:
        return True
    else:
        return False

def pow_k(x, n):
    ans = 1
    while n:
        if n % 2:
            ans *= x
        x *= x
        n >>= 1
    return ans

"""
def nibu(x,n,r):
    ll = 0
    rr = r
    while True:
        mid = (ll+rr)//2

    if rr == mid:
        return ll
    if (ここに評価入れる):
        rr = mid
    else:
        ll = mid+1
"""

s = [list(input())[:-1] for i in range(2)]

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

Submission status: Accepted

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

Submission status: Accepted

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

def resolve():
    C = [input(), 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")


if '__main__' == __name__:
    resolve()

Submission status: Accepted

Solution code:
c1 = list(input())
c2 = list(input())
if c1[::-1]==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:
a = list(input())
b = list(input())

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

Submission status: Accepted

Solution code:
A = input()
B = input()
if A[1] != B[1]:
  print("NO")
  exit()
elif A[0] == B[2] and B[0]== A[2]:
  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()
print("YES" if c1==c2[::-1] else "NO")

Submission status: Accepted

Solution code:
S1=str(input())
S2=str(input())
if S1 == S2[2]+S2[1]+S2[0]:
  print('YES')
else:
  print('NO')

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

Submission status: Accepted

Solution code:
print('YES') if input()[::-1]==input() 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=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:
a = list(input())
b = list(input())
if a == list(reversed(b)):
    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:
# coding: utf-8

#N, Q = map(int,input().split())
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 = list(input())
d = list(input())

for i in range(3):
    if c[2 - i] != d[i]:
        print("NO")
        exit()

print("YES")

Submission status: Accepted

Solution code:
from sys import stdin

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

if C[0] == D[2] and C[1] == D[1] and C[2] == D[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:
icase=0    
if icase==0:
    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:
import sys
x = input()
y = input()

for i in range(3):
  if x[i] != y[2-i]:
    print("NO")
    sys.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:
input1 = input()
input2 = input()
if input1[0] == input2[2] and input1[1] == input2[1] and input1[2] == input2[0]:
  print('YES')
else:
  print('NO')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def main():
    r1 = input()
    r2 = input()
    r1 = r1[::-1]

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

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() for _ in range(2))
print('YES' if list(a) == list(reversed(b)) else 'NO')

Submission status: Accepted

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

Submission status: Accepted

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

rc1 = c1[::-1]
rc2 = c2[::-1]

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

Submission status: Accepted

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

Submission status: Accepted

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

c0=[]
for i in range(3):
  c0.append(c[0][i])
c1=[]
for i in range(3):
  c1.append(c[1][i])
  
if c0[0]==c1[2] and c0[1]==c1[1] and c0[2]==c1[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()
print('YES' if a == b[::-1] and b == a[::-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:
nim = input()
sam = input()
print('YES' if nim[::-1] == sam else'NO' )

Submission status: Accepted

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

    s2 = s2[::-1]

    print('YES' if s1 == s2 else 'NO')

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

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

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

Submission status: Accepted

Solution code:
c1 = input()
c2 = input()
if (c1 == c2[::-1]) and (c2 == c1[::-1]):
    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 == ''.join(reversed(list(c2))) and c2 == ''.join(reversed(list(c1))):
  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:
C_1=input()
C_2 = 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:
s_1 = input()
s_2 = input()
if s_1[0] == s_2[2] and s_1[1] == s_2[1] and s_1[2] == s_2[0]:
  print("YES")
else:
  print("NO")

Submission status: Accepted

Solution code:
import sys
import os

ii = lambda: int(sys.stdin.buffer.readline().rstrip())
il = lambda: list(map(int, sys.stdin.buffer.readline().split()))
fl = lambda: list(map(float, sys.stdin.buffer.readline().split()))
iln = lambda n: [int(sys.stdin.buffer.readline().rstrip()) for _ in range(n)]

iss = lambda: sys.stdin.buffer.readline().decode().rstrip()
sl = lambda: list(map(str, sys.stdin.buffer.readline().decode().split()))
isn = lambda n: [sys.stdin.buffer.readline().decode().rstrip() for _ in range(n)]


def main():
    if os.getenv("LOCAL"):
        sys.stdin = open("input.txt", "r")

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


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys
input = lambda: sys.stdin.readline().rstrip() 

def resolve():
    C = [input() for _ in range(2)]

    ok = True
    for i in range(3):
        if C[0][i] != C[1][2-i]:
            ok = False
    if ok:
        print('YES')
    else:
        print('NO')

if __name__ == '__main__':
    resolve()

Submission status: Accepted

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

c = a[::-1]

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
if input() == input()[::-1]:
    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 == c2[::-1]:
  print('YES')
else:
  print('NO')

Submission status: Accepted

Solution code:
a = input()
b = input()
for i in range(3):
  if a[i] != b[-(i+1)]:
    print("NO")
    exit()
print("YES")

Submission status: Accepted

Solution code:
s_1 = input()
s_2 = input()
if s_1[0] == s_2[2] and s_1[1] == s_2[1] and s_1[2] == s_2[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:
S0 = input()
S1 = input()

ans = "YES"
for i in range(3):
    if S0[i] != S1[2-i]:
        ans ="NO"
        break

print(ans)

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())

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

Submission status: Accepted

Solution code:
import itertools
def main():
  s1 = input()
  s2 = input()
  print("YES" if s1 == s2[::-1] else "NO")
if __name__ == '__main__':
  main()

Submission status: Accepted

Solution code:
C11, C12, C13 = map(str, input())
C21, C22, C23 = map(str, input())
if C11+C12+C13==C23+C22+C21:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
def main():
    cs = [list(input()) for _ in range(2)]
    ul = cs[0][0]
    uc = cs[0][1]
    ur = cs[0][2]
    bl = cs[1][0]
    bc = cs[1][1]
    br = cs[1][2]

    if ul == br and uc == bc and ur == bl:
        ans = 'YES'
    else:
        ans = 'NO'

    print(ans)


if __name__ == "__main__":
    main()

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:
C = [list(input()) for _ in range(2)]
D = [list(reversed(C[1])), list(reversed(C[0]))]

ans = 'YES' if C == D else 'NO'
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c1 = str(input())
c2 = str(input())
if c1 == c2[::-1]:
    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:
import sys

s = sys.stdin.read().split()

def main():
    ans = 'YES' if s[0] == s[1][::-1] else 'NO'
    print(ans)

if __name__ ==  '__main__':
    main()

Submission status: Accepted

Solution code:
# ABC 077: A – Rotation
c = [input() for _ in range(2)]
print('YES' if c[0] == c[1][::-1] and c[1] == c[0][::-1] 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:
n1=list(input().rstrip())
n2=list(input().rstrip())
ans="YES"
for i in range(len(n1)):
  if n1[i]!=n2[-1-i]:
    ans="NO"
    break
print(ans)

Submission status: Accepted

Solution code:
row1 = input()
row2 = input()

if row1[0] == row2[2] and row1[1] == row2[1] and row1[2] == row2[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:
import sys
import copy
import math
import bisect
import pprint
import bisect
from functools import reduce
from copy import deepcopy
from collections import deque

if __name__ == '__main__':
    a = input()
    b = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A = input() + input()
print('YES' if A[0] == A[5] and\
               A[1] == A[4] and\
               A[2] == A[3] else '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,B,C=input();D,E,F=input();print('YNEOS'[A!=F or B!=E or C!=D::2])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
c1,c2 = [list(input()) for i in range(2)]
c2.reverse()
print('YES' if c1==c2 else 'NO')

Submission status: Accepted

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

if c1 == c3:
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

YES = "YES"  # type: str
NO = "NO"  # type: str


def main():
    # Failed to predict input format
    c = [input() for _ in range(2)]
    print(YES if c == [ci[::-1] for ci in c[::-1]] else NO)


if __name__ == '__main__':
    main()

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 _ in range(2)]

for i in range(2):
    for j in range(3):
        if C[i][j] != C[1-i][2-j]:
            print('NO')
            exit()

print('YES')

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 math



a=input()
b=input()


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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
def fastio():
    from io import StringIO
    from atexit import register
    global input
    sys.stdin = StringIO(sys.stdin.read())
    input = lambda : sys.stdin.readline().rstrip('\r\n')
    sys.stdout = StringIO()
    register(lambda : sys.__stdout__.write(sys.stdout.getvalue()))
fastio()

INF = 10**20
MOD = 10**9 + 7
I = lambda:list(map(int,input().split()))
# from math import gcd
from math import ceil
from collections import defaultdict as dd, Counter
from bisect import bisect_left as bl, bisect_right as br

s = input()
t = input()

ans = 'NO'
if s == t[::-1]:
    ans = 'YES'
print(ans)

Submission status: Accepted

Solution code:
s1 = input()
s2 = input()
ans = {True:"YES",False:"NO"}
print(ans[s1==s2[::-1]])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
str = input()
newStr = input()
def f(s):
    s = list(s)
    if len(s) <= 1:
        return s
    i = 0
    length = len(s)
    while i< length/2:
        s[i],s[length-1-i] = s[length-1-i],s[i]
        i += 1
    return ''.join(s)
if newStr == f(str):
    print('YES')
else:
    print('NO')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
C1 = list(input())
C2 = list(input())
if C1 == C2[::-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:
c11,c12,c13 = map(str,input())
c21,c22,c23 = map(str,input())
if c11 == c23 and c12 == c22 and c13 == c21:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import math

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()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = [ list(input()) for i in range(2)]
t = [ [0 for j in range(3)] for i in range(2) ]
for i in range(2):
    for j in range(3):
        t[1-i][2-j] = s[i][j]
print("YES" if s == t else "NO")

Submission status: Accepted

Solution code:
f = input()
g = input()
g = list(g)
g.reverse()
p = (''.join(g))
if p == f:
  print("YES")
else:
  print("NO")

Submission status: Accepted

Solution code:
def reverse(string):
    string = string[::-1]
    return string


l=input()
m=input()
if l == reverse(m):
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
row1 = input()
row2 = input()

r1 = row1[::-1]
r2 = row2[::-1]

if(row1 == r2 and row2 == r1):
    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:

x = list(input())
y = list(input())



if (x[0] != y[-1] or x[-1] != y[0] or x[1] != y[1] or len(x)!=3 or len(y)!=3):
    print( "NO")
else:
    print( "YES")

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
S1 = list(input())
S2 = list(input())

flag = 0
for i in range(3):
  if S1[i] != S2[2-i]:
    flag = 1

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

Submission status: Accepted

Solution code:
a=input()
b=input()
c=''
for i in range(3):
    c+=a[2-i]
if(c==b):
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
x = list(input())
y = list(input())
if ( len(x)!=3 or len(y)!=3 or x[0] != y[-1] or x[-1] != y[0] or x[1] != y[1]):
    print( "NO")
else:
    print( "YES")

Submission status: Accepted

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

str2=str2[::-1]

if(str1==str2):
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
n = input()
m = input()
m = "".join(reversed(m))
if n==m:
  print("YES")
else:
  print("NO")

Submission status: Accepted

Solution code:
r1 = input();
r2 = input();
if r1[0] == r2[2] and r1[1] == r2[1] and r1[2] == r2[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:
row1 = str(input())
row2 = str(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=input()
b=input()
rev = ''.join(reversed(a))
if rev==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 = input()
r = input()
s = s + r
if s == s[: : -1]:
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
s = input()
r = input()
s = s + r
r = ''.join(reversed(s))
if s == r:
    print("YES")
else: print("NO")