Switch Game

 

#include <cstdio>

int main()
{
	int n;
	while(scanf("%d", &n) != EOF)
	{
		int k = 0;
		for(int i = 1; i <= n; ++ i)
			if(n % i == 0)	k ++;
			
		if(k % 2 == 0)	printf("0\n");
		else	printf("1\n");
	}
	
	return 0;
}

  

posted @ 2019-08-03 21:41  青衫客36  阅读(153)  评论(0编辑  收藏  举报