A - Rotation 解説 /

実行時間制限: 2 sec / メモリ制限: 256 MB

配点 : 100

問題文

2 マス、横 3 マスのマス目が与えられます。上から i 行目、左から j 行目のマスの色は、C_{ij} で表されます。

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

制約

  • C_{ij}(1 \leq i \leq 2, 1 \leq j \leq 3) は英小文字である。

入力

入力は以下の形式で標準入力から与えられる。

C_{11}C_{12}C_{13}
C_{21}C_{22}C_{23}

出力

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


入力例 1

pot
top

出力例 1

YES

マス目を 180 度回転させると、元のマス目と一致します。


入力例 2

tab
bet

出力例 2

NO

マス目を 180 度回転させても、元のマス目と一致しません。


入力例 3

eye
eel

出力例 3

NO

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