import java.util.Scanner;
public class Main {
public static void main(String[] args) {
// TODO Auto-generated method stub
Scanner sc = new Scanner(System.in);
int n = sc.nextInt();
int g = n % 10;
int b = n / 100;
if(g == b){
System.out.println("Y");
}else{
System.out.println("N");
}
}
}
/**************************************************************
Problem: 1628
User: admin
Language: Java
Result: Accepted
Time:678 ms
Memory:40264 kb
****************************************************************/