Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- int main()
- {
- int t;
- int a,b,c;
- scanf("%d", &t);
- int d=0;
- for(int i=0;i<t;i++)
- {
- scanf("%d %d", &a,&b);
- if(b==0)
- {
- printf("Case %d: not divisible\n",++d);
- continue;
- }
- c=a/b;
- if(c*b!=a)
- {
- printf("Case %d: not divisible\n",++d);
- }
- else
- {
- printf("Case %d: divisible\n",++d);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement