90分求调
  • 板块灌水区
  • 楼主gzwm
  • 当前回复11
  • 已保存回复11
  • 发布时间2024/8/26 10:48
  • 上次更新2024/8/26 13:53:24
查看原帖
90分求调
1017617
gzwm楼主2024/8/26 10:48

传送门

#include<bits/stdc++.h>
using namespace std;
int main(){
	double s,v,t;
	int x=470,y,z;
	cin>>s>>v;
	t=ceil(s/v); 
	x-=t;
	if(t>x){
		x+=1440;
	}
	y=x/60;
	z=x%60;
	if(y<10){
		if(z<10)
			cout<<0<<y<<":"<<0<<z;
		else
			cout<<0<<y<<":"<<z;
	}else{
		 if(z<10)
			cout<<y<<":"<<0<<z;
		else
			cout<<y<<":"<<z;
	}
	return 0;
}

2024/8/26 10:48
加载中...