- 题解
有人出题解吗
- 1 年前 @
1 条评论
-
刘炳程 @ 1 年前
上学迟到???
- 1
上学迟到???
#include <iostream>
#include <cstdio>
#include <cmath>
using namespace std;
double s,v;
int t,h,m;
int main()
{
cin >> s >> v;
t = ceil(s/v)+10;//ceil函数是向上取整,在cmath库里
h = (1920-t)/60;
m = (1920-t)%60;
if(h>=24) h-=24;
if(h<10)printf("0%d:%d",h,m);
else printf("%d:%d",h,m);
return 0;
}
题解哥
2021-2023 莱芜一中信息学奥赛在线评测系统 LaiWu No.1 Middle School Online Judge System
Powered By Loi62-Hywel