不知道为啥就全WA了QAQ
下面是源代码
#include<bits/stdc++.h>
using namespace std;
int main()
{
int t,h,m;
double s,v,t1,t2;
cin>>s>>v;
t1=s/v;
t=t1;
t2=t;
if(t1>t2)
{
t+=1;
}
t+=10;
if(t<60)
{
cout<<7<<":"<<60-t;
}
else
if(60<t<480)
{
h=t/60;
m=t-h*60;
cout<<8-m-1<<":"<<60-m;
}
else
{
if(t==480)
{
cout<<"00:00";
}
else
{
h=t/60;
m=t-h*60;
h=h-8;
if(24-h>=10)
if(60-m>=10)
cout<<24-h-1<<":"<<60-m;
else
cout<<24-h-1<<":0"<<60-m;
else
cout<<"0"<<24-h-1<<":0"<<60-m;
}
}
return 0;
}
求指出错误并给予修改思路 如果能给几组样例就更好啦 谢谢大佬awa