View Code of Problem 20

#include<iostream>
using namespace std;
int main(){
	int n;
	while(cin>>n){
		if(n==1 || n==2){
			cout<<"Yes"<<endl;
		}
		if(n>2){
			if(n%3==0){
				cout<<"No"<<endl;
			}
			else{
				cout<<"Yes"<<endl;
			}
		}
	}
}

Double click to view unformatted code.


Back to problem 20