#include<bits/stdc++.h>
using namespace std;
int main(){
	int n;
	cin>>n;
	if(n%2==0||n%3==0){
		cout<<"Y";
	}else{
		cout<<"N";
	}
} 
/**************************************************************
	Problem: 1673
	User: linzihang
	Language: C++
	Result: Accepted
	Time:13 ms
	Memory:2072 kb
****************************************************************/