70分求助
查看原帖
70分求助
408722
liuxiaohan楼主2021/9/11 10:07
#include <iostream>
using namespace std;
int main(){
	int h,m;
	int s,v;
	cin>>s>>v; 
	int t;
	t=s/v;
	if(s%v!=0){
		t++;
	}
	h=7;
	m=50-t;
	while(m<0){
		m+=60;
		h-=1;
	}
	if(m<10){
		cout<<"0"<<h<<":"<<"0"<<m<<endl;
	}
	else{
		cout<<"0"<<h<<":"<<m<<endl;
	}
	return 0;
} 
2021/9/11 10:07
加载中...