uva408 Uniform Generator
View Code
#include<stdio.h> #include<string.h> #include<math.h> int main() { int m, n, k; while(scanf("%d%d",&m,&n) == 2) { printf("%10d%10d",m,n); if(m < n){k = m; m = n; n = k;} while(n) { k = m%n; m = n; n = k; } if(m == 1) puts(" Good Choice"); else puts(" Bad Choice"); puts(""); } return 0; }