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: Wrong Answer

Solution code:
a=str(input())
b=str(input())
c=0
d=0
for i in range(3):
    slice=a[c:c+1]
    c=c+1
for j in range(3):
    slice=b[d:d+1]
    d=d+1
if(a[0:1]==b[2:3] and a[1:2]==b[1:2] and a[2:3]==b[0:1]):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

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

    for i in range(3):
        j = 2-i

        if C[0][i] != C[1][j]:
            print("NO")
            return

    print("Yes")

main()

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
def judge(A, B):
  i=0
  if len(A) != len(B):
    return False
  else:
    while i<len(A):
      if A[i] != B[len(B)-i-1]:
        return False
      i+=1
    return True

A=input()
B=input()

if judge(A, B):
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
def judge(A, B):
  i=0
  if len(A) != len(B):
    return False
  else:
    while i<len(A):
      if A[i] != B[len(B)-i-1]:
        return False
      i+=1
    return True
 
A=input()
B=input()
 
if judge(A, B):
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

Solution code:
def judge(A, B):
  i=0
  if len(A) != len(B):
    return False
  else:
    while i<len(A):
      if A[i] != B[len(B)-i-1]:
        return False
    return True

A=input()
B=input()

if judge(A, B):
  print("Yes")
else:
  print("No")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
# coding: utf-8

#整数の入力
#a = int(input())
#b = int(input())
#スペース区切りの整数の入力
#a, b, c = map(int, input().split())
#文字列の入力
s1 = input()
s2 = input()

if s1[0] == s2[2] and s1[1] == s2[1] and s1[2] == s2[0]:
    ans = "Yes"
else :
    ans = "No"

#出力
print(ans)

Submission status: Wrong Answer

Solution code:
a = input()
b = input()
if "".join(reversed(a)) == b:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
import numpy as np
import pdb

def main():
    row1 = list(raw_input())
    row2 = list(raw_input())

    matoriginal = np.array([row1, row2])
    rotated1 = row2[::-1]
    rotated2 = row1[::-1]
    matrotate = np.array([rotated1, rotated2])

    if np.prod(matoriginal == matrotate):
        print 'yes'
    else:
        print 'no'


if __name__ == '__main__':
    main()

Submission status: Wrong Answer

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

if ((x[0][0]==x[1][2])and(x[0][2]==x[1][0])) and x[0][1]==x[1][1]:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:

a = input()
b = reversed(input())

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

Submission status: Wrong Answer

Solution code:
import sys
C1 = sys.stdin.readline()
C2 = sys.stdin.readline()
c1 = C1.rstrip()
c2 = C2.rstrip()


c3 = c2[::-1]
if c1 == c3:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
import sys
C1 = sys.stdin.readline()
C2 = sys.stdin.readline()
c1 = C1.rstrip()
c2 = C2.rstrip()
c3 = c2[::-1]
if c1 == c3:
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

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

if (C1[0]==C2[2])&(C1[1]==C2[1])&(C1[2]==C2[0]):
    print("Yes")
else:
    print("No")

Submission status: Wrong Answer

Solution code:
a = [0,0]
temp = [0,0]

for k in range(2):
    temp[k] = input()
    a[1-k] = temp[k][::-1]

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

Submission status: Wrong Answer

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: Wrong Answer

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

def main():
    matrix = []
    for _ in range(2):
        matrix.append(list(input()))

    if matrix[0][0] == matrix[1][2] \
        and matrix[0][1] == matrix[1][1] \
        and matrix[0][2] == matrix[1][0]:
        print("Yes")
    else:
        print("No")

if __name__ == '__main__':
    main()

Submission status: Wrong Answer

Solution code:
input1 = input().split(' ')
input2 = input().split(' ')

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

Submission status: Wrong Answer

Solution code:
input1 = input().split(' ')
input2 = input().split(' ')

if input1[::-1] == input2[::] :
    print("Yes")
else :
    print("No")

Submission status: Wrong Answer

Solution code:
a=input().split()
a=list(a)
b=input().split()
b=list(b)
n=len(a)
N=1
for i in range(n):
  if(a[i]!=b[-(i+1)]):
     N=0
if(N==1):
     print("YES")
else:
     print("NO")

Submission status: Wrong Answer

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

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

Submission status: Wrong Answer

Solution code:
up = raw_input()
under = raw_input()
print(up,under[::-1])
if up == under[::-1]:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
up = raw_input()
under = raw_input().strip()
print(up,under[::-1])
if up == under[::-1]:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
#A_Rotation
def rotation(c1, c2):
	if str(c1) == str(c2)[:-1]:
		print("YES")
	else:
		print("NO")

if __name__ == "__main__":
	c1 = input()
	c2 = input()
	rotation(c1, c2)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
text1 = input()
text2 = input()

if text1 == text2[::-1]:
    print("OK")
else:
    print("NO")

Submission status: Wrong Answer

Solution code:
# coding: utf-8

N = input()
M = input()
N1 = list(N)
M1 = list(M)
     
if N1[0]==M1[2] and N1[1]==M1[1]:
    if N1[2]==M1[0]:
        print("YES")
else:
    print("NO")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
word1 = input()
word2 = input()
point= 0

for i in range(0,3):
    for j in range(2,-1,-1):
        if word1[i] == word2[j]:
            point+=1

if point == 3:
    print("YES")
else:
    print("NO")

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

rev_up = up[::-1]
rev_down = down[::-1]

if rev_up == down and rev_down == up:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

Solution code:
line1 = input().strip()
line2 = input().strip()
if line1[0] == line2[2] and line1[1] == line2[1] and line1[2] == line2[0]:
    print(True)
else:
    print(False)

Submission status: Wrong Answer

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

Submission status: Wrong Answer

Solution code:
C=[input() for i in range(2)]
i=0
while i<2 and C[0][i]==C[1][2-i]:
    i+=1
p="NO"
if i==2:
    p="YES"
print(p)

Submission status: Wrong Answer

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: Wrong Answer

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: Wrong Answer

Solution code:
row1 = input()
row2 = input()
if row1 == row2[::-1]:
    print('Yes')
else:
    print('No')

Submission status: Wrong Answer

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

Submission status: Wrong Answer

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

Submission status: Time Limit Exceeded

Solution code:
def judge(A, B):
  i=0
  if len(A) != len(B):
    return False
  else:
    while i<len(A):
      if A[i] != B[len(B)-i-1]:
        return False
    return True
 
A=input()
B=input()
 
if judge(A, B):
  print("YES")
else:
  print("NO")

Submission status: Accepted

Solution code:
a,b=[input() for i in range(2)]
c=a[::-1];d=b[::-1]

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:

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

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

else:
    print('NO')

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:
S1,S2=[input() for _ in range(2)]
print("YES") if S1[2]==S2[0] and S1[1]==S2[1] and S1[0]==S2[2] 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:
li = list(input())
li1 = list(input())

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

Submission status: Accepted

Solution code:
def atc_077a(input_value: str) -> str:
    C1 = input_value[0]
    C2 = input_value[1]

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


C1 = input()
C2 = input()
print(atc_077a([C1, C2]))

Submission status: Accepted

Solution code:
# 2段目の文字列を逆にして1段目の文字列と一致すればいい
c = input('')
d = input('')

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

Submission status: Accepted

Solution code:
import bisect,collections,copy,heapq,itertools,math,string
import sys
def I():
    # 1 line 1 int
    return int(sys.stdin.readline().rstrip())
def LI():
    # 1 line n ints
    return list(map(int,sys.stdin.readline().rstrip().split()))
def S():
    # 1 line 1 string
    return sys.stdin.readline().rstrip()
def LS():
    # 1 line n strings
    return list(sys.stdin.readline().rstrip().split())

C1 = S()
C2 = S()

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

Submission status: Accepted

Solution code:
import bisect,collections,copy,heapq,itertools,math,string
import sys
def I():
    #1 line 1 int
     return int(sys.stdin.readline().rstrip())
def LI():
    #1 line n int
     return list(map(int,sys.stdin.readline().rstrip().split()))
def S():
    #1 line 1 string
     return sys.stdin.readline().rstrip()
def LS():
    #1 line n strings
     return list(sys.stdin.readline().rstrip().split())

C1=S()
C2=S()

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 bisect,collections,copy,heapq,itertools,math,string
import sys
def I():
    # 1 line 1 int
    return int(sys.stdin.readline().rstrip())
def LI():
    # 1 line n ints
    return list(map(int,sys.stdin.readline().rstrip().split()))
def S():
    # 1 line 1 string
    return sys.stdin.readline().rstrip()
def LS():
    # 1 line n strings
    return list(sys.stdin.readline().rstrip().split())

C1 = S()
C2 = S()

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:
first = input()
second = input()

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

Submission status: Accepted

Solution code:
i = input()
j = input()
if i == j [::-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:
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:
# ソートかけてどちらも同じだとYES

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

# print(c1)
# print(c2)

c1_str = ''.join(c1)
# c2_str = ''.join(c2)

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

if c1_str == c2_str_reverse:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
a = list(map(str, input()))
b = list(map(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:
#入力例は合うがWAになる

A = input()
B = input()


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

#YESとNOにしないといけないところをYes、Noになっていた

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# 077_a
C1=input()
C2=input()
# (1<=i and i<=2) and (1<=j and j<=3):

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

Submission status: Accepted

Solution code:

c1=input()
c2=input()

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

Submission status: Accepted

Solution code:
c1, c2 = [input() for _ in range(2)]


def answer(c1: str, c2: str) -> str:
    if c1[0] == c2[2] and c1[2] == c2[0] and c1[1] == c2[1]:
        return 'YES'
    else:
        return 'NO'

print(answer(c1, c2))

Submission status: Accepted

Solution code:
c = [""] * 2
c[0] = input()
c[1] = input()
s = True
for i in range(2):
  for j in range(3):
    if c[i][j] != c[-i-1][-j-1]: s = False
if s: print('YES')
else: print('NO')

Submission status: Accepted

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

if a==b[::-1] and b ==a[::-1]:
    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:
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:
s=input()
t=input()
t=t[::-1]
if s==t:
  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:
a = list(input())
b = list(input())

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

Submission status: Accepted

Solution code:
x = list(input())
y = list(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:
with open(0) as f:
    C = ''.join(f.read().split())
print('YES' if C == C[::-1] else 'NO')

Submission status: Accepted

Solution code:
a=input()
print("YES") if input()==a[::-1] 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:
'''
問題：
    縦 2 マス、横 3 マスのマス目が与えられます。
    上から i 行目、左から j 行目のマスの色は、Cij で表されます。

    このマス目を 180 度回転させたとき、
    元のマス目と一致するなら YES を、そうでないなら NO を出力するプログラムを作成してください。
'''

'''
制約：
    Cij（1 ≦ i ≦ 2、 1 ≦ j ≦ 3）は英小文字である。
'''

# 標準入力から Cij、Cji を取得する
cij = str(input())
cji = str(input())

reverse_cij = cij[2] + cij[1] + cij[0]  # cij を180度回転させた文字列

result = ""
if cji == reverse_cij:
    result = "YES"
else:
    result = "NO"

print(result)

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
x = str(input())
y = str(input())

conditions = x[0] == y[2] and x[1] == y[1] and x[2] == y[0]
if conditions:
    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:
c_u=input()
c_d=input()
if c_u==c_d[::-1]:
    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:
C=[list(input()) for _ in range(2)]
flag=True
for i in range(2):
    for j in range(3):
        if C[i][j]!=C[1-i][2-j]:
            flag=False
if flag:
    print("YES")
else:
    print("NO")

Submission status: Accepted

Solution code:
C123=list(input())
C456=list(reversed(input()))

if C123 == (C456):
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
#77
data1=list(input())
data2=list(input())
if (data1[0]==data2[2] and data1[1]==data2[1] and data1[2]==data2[0]):
    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:
C1, C2 = [input() for i in range(2)]
print('YES' if C1 == C2[::-1] else 'NO')

Submission status: Accepted

Solution code:
word1, word2 = [input() for i in range(2)]
if word1[0] == word2[2] and word1[1] == word2[1] and word1[2] == word2[0]:
    print('YES')
else:
    print('NO')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a=input()
b=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()
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:
# A - Rotation
# https://atcoder.jp/contests/abc077/tasks/abc077_a

a = input()
b = input()

result = 'YES'
i = 0
j = -1
while i < len(a):
    if a[i] != b[j]:
        result = 'NO'
        break
    i += 1
    j -= 1

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

if c2 == c1[::-1] and 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:
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:
# 077a

def atc_077a(input_value: str) -> str:
    C1 = input_value[0]
    C2 = input_value[1]

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


C1 = input()
C2 = input()
print(atc_077a([C1, C2]))

Submission status: Accepted

Solution code:
C1 = str(input())
C2 = str(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:
import math
b=input()
c=[]
for i in range(len(b)):
	c.append(b[i])
#a = list(map(int,input().split()))
#b = list(map(int,input().split()))
#s=int(input())

f=input()
t=[]
for i in range(len(f)):
	t.append(f[i])
d=[]
for i in range(len(c)):
	d.append(c[-(i+1)])
	
if d==t:
	print("YES")
else:
	print("NO")

Submission status: Accepted

Solution code:
C1 = str(input())
C2 = str(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:
Ci = input()
Cj = input()

if Ci[0] == Cj[-1] and Ci[1] == Cj[-2] and Ci[2] == Cj[-3]:
    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:
def main():
    c_list = [list(input()) for _ in range(2)]
    if c_list[0][0] == c_list[1][2] and c_list[0][1] == c_list[1][1] and c_list[0][2] == c_list[1][0]:
        print("YES")
    else:
        print("NO")


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
data1 = input()
data2 = input()

count = 3 -1
sw = 0
i = 0
j = len(data2)-1
while i <= count:
    if data1[i] == data2[j]:
        sw += 1
    i += 1
    j -= 1
if sw == 3:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

if s[0] == t[2] and s[1] == t[1] and s[2] == t[0]:
    result = "YES"
else:
    result = "NO"

print(result)

Submission status: Accepted

Solution code:
# A - Rotation
line1 = input()
line2 = input()
my_list1 = []
my_list2 = []
 
for i in line1:
    my_list1.append(i)
 
for i in line2:
    my_list2.append(i)
 
my_list2.reverse()
 
if my_list1 == my_list2:
    print('YES')
else:
    print('NO')
 
# print(my_list1, my_list2)

Submission status: Accepted

Solution code:
a = input()
b = input()
# 最初の文字と最後の文字を入れ替えても同じになれば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:
c1 = input()
c2 = input()

# マス目を 180度回転 させたとき、元のマス目と一致するなら YES を、そうでないなら NO を出力せよ。

if [c1[0], c1[1], c1[2]] == [c2[2], c2[1], 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 = str(input())
C2 = str(input())

# 文字列の結合
ori_str = C1 + C2

# 末尾から１文字ずつ取得して逆さま文字を生成
rev_str = ori_str[-1::-1]

# 比較結果を出力
if ori_str == rev_str:
    print("YES")
else:
    print("NO")

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
C=input()+input()
print("YNEOS"[1 in[1 for i in range(3)if C[i]!=C[-i-1]]::2])

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import sys

readline = sys.stdin.readline
MOD = 10 ** 9 + 7
INF = float('INF')
sys.setrecursionlimit(10 ** 5)


def main():
    x = input()
    y = input()

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


if __name__ == '__main__':
    main()

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

new_str = ''.join(list(reversed(a)))
print('YES' if new_str==b else '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()
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()                      
                                 
c = a[0] + a[1] + a[2]           
d = b[-1] + b[-2] + b[-3]        
                                 
if c == d:                       
    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_13 == C_21 and C_12 == C_22:
    print('YES')
else:
    print('NO')

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
import numpy as np

Cij = [list(input()) for _ in range(2)]
Cij_inv = np.rot90(Cij, 2)

if np.array_equal(Cij, Cij_inv):
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
C = [str(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]:
  ans = "YES"
else:
  ans = "NO"
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
first_line = input()
second_line = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=str(input())
t=str(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 = list(map(str, input()))
c2 = list(map(str, input()))
if c1[2]==c2[0] and c1[1]==c2[1] and c1[0]==c2[2]:
  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:
S1 = input()
S2 = input()
if S1[::-1] == S2:
  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, c2 = (input() for s in range(0,2))
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()[::-1]
print("YES" if a==b 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")
  exit()
print("NO")

Submission status: Accepted

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

Submission status: Accepted

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

up.reverse()
if up == down:
    print('YES')
else:
    print('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:
a=ina=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()[::-1]

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

Submission status: Accepted

Solution code:
c1 = str(input())
c2 = str(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[::-1]== C2 and C2[::-1] == C1 else "NO")

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

Submission status: Accepted

Solution code:
i = input()
j = input()

if i == j[::-1]:
    print('YES')
else:
    print('NO')

Submission status: Accepted

Solution code:
C=[0,0]
C[0]=list(map(str,input()))
C[1]=list(map(str,input()))
ans="NO"
X=C[0][::-1]
if C[1]==X:
    ans="YES"
print(ans)

Submission status: Accepted

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

Submission status: Accepted

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