Advertisement
shipu_a

Div 2 Problem C

Jan 14th, 2013
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.31 KB | None | 0 0
  1. #include<cstdio>
  2. int main()
  3. {
  4.     int test,t=0,a,b,p;
  5.     scanf("%d",&test);
  6.     while(test--)
  7.     {
  8.         scanf("%d%d",&a,&b);
  9.         p=(a+b)%3;
  10.         if(p==0)
  11.             printf("Case %d# All Groups Are OK\n",++t);
  12.         else
  13.             printf("Case %d# %d\n",++t,p);
  14.     }
  15.     return 0;
  16. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement