Advertisement
Plabon_dutta

Old time-3084 uri

Jun 7th, 2020
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. #include<stdio.h>
  2. int main()
  3. {
  4. int a,b,c,d;
  5. while(scanf("%d %d", &a, &b)!= EOF){
  6. c=a/30;
  7. d=b/6;
  8. if(c>=0 && c<=9 && d>=0 && d<=9){
  9. printf("0%d:0%d\n",c,d);
  10. }
  11. else
  12. if(c>9 && d>=0 && d<=9){
  13. printf("%d:0%d\n",c,d);
  14. }
  15. else
  16. if(c>=0 && c<=9 && d>9){
  17. printf("0%d:%d",c,d);
  18. }
  19. }
  20. return 0;
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement