408 - Uniform Generator

#include<stdio.h>
int gcd(int a,int b)  
{  
	if(!b) return a;
	else return  gcd(b,a%b);  
}  
int main()
{
	int s,m;
	while(scanf("%d%d",&s,&m)!=EOF)
	{
		printf("%10d%10d    ",s,m); 
		if(gcd(s,m)==1) puts("Good Choice");
		else puts("Bad Choice");
		printf("\n");
	}
	return 0;
}


posted @ 2013-05-24 22:19  javawebsoa  Views(158)  Comments(0)    收藏  举报