#include<cstdio>
#include<iostream>
#include<cstring>
using namespace std;
int main()
{
	char S[100];
	char T[100];
	char cmp[100];
	char sign;
	scanf("%s",&S);
	scanf("%s",&T);
	int len1=strlen(S);
	int len2=strlen(T);
	for(int i=0;i<len1/2;i++)
	{
		sign=S[i];
		S[i]=S[len1-i-1];
		S[len1-i-1]=sign;
	} 
	
	for(int i=1;i<1+(len1-1)/2;i++)
	{
		sign=S[i];
		S[i]=S[len1-i];
		S[len1-i]=sign;
	}
	//for(int i=0;i<len1;i++)
//	cout<<S[i]<<" ";
	if(!strcmp(S,T))
	cout<<"Yes";
	else
	cout<<"No";
}