TOPIC
Wrong Answer 100%
smsourav asked 3 years ago
Hello I am Sourav. I almost finished the problem but judge showing me 100% wrong answer where the program is almost correct.
#include <stdio.h>
int main()
{
int h, m, hp, mp;
while(scanf("%d%d", &h, &m)!=EOF)
{
if(h==0 && m==0)
{
hp = 0; mp = 0;
}
else if(h==360 && m==360){
hp = 0; mp = 0;
}
else{
hp = h/30; mp = m/6;
}
printf("%02d:%02d\n", hp, mp);
if(h==0 && m==0)
{
break;
}
}
return 0;
}