a=eval(input())

b=eval(input())

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

if rev==b:

    print("YES")

else:

    print("NO")
str1=eval(input())

str2=eval(input())



str2=str2[::-1]



if(str1==str2):

    print('YES')

else:

    print('NO')
a = eval(input())
b = eval(input())
rev = "".join(reversed(a))
if rev == b:
    print("YES")
else:
    print("NO")

str1 = eval(input())
str2 = eval(input())
str2 = str2[::-1]
if str1 == str2:
    print("YES")
else:
    print("NO")

-a = eval(input()) -b = eval(input()) -rev = "".join(reversed(a)) -if rev == b: +str1 = eval(input()) +str2 = eval(input()) +str2 = str2[::-1] +if str1 == str2: