ice_moon_soul @ 2023-10-07 20:38:38
#include <iostream>
#include <algorithm>
using namespace std;
int main()
{
int s = 0, v = 0,z;
cin >> s >> v;
if (s / v == 0) z = s / v;
else z = s / v + 1;
int rec1 = (z + 10) / 60;
int rec2 = (z + 10) % 60;
if (7 - rec1 >= 0)
{
if (60 - rec2 >= 10)
printf("0%d:%d", 7 - rec1, 60 - rec2);
else
printf("0%d:0%d", 7 - rec1, 60 - rec2);
}
else
{
if (60 - rec2 >= 10)
printf("%d:%d", 31 - rec1, 60 - rec2);
else
printf("%d:0%d", 31 - rec1, 60 - rec2);
}
return 0;
}
by Hamdi @ 2023-10-07 21:28:00
前排
可能是昨天出门时间第一位为0吧
by Hamdi @ 2023-10-07 21:36:26
我也是90分
by Hamdi @ 2023-10-09 13:42:30
#include<bits/stdc++.h>
using namespace std;
double a;
int b;
int main()
{
cin >> a >> b;
int t = ceil(a / b);
t += 10;
int f = 60 * (24 + 8) - t;
int s = (f / 60) % 24;
int k = f % 60;
printf("%02d:%02d\n", s, k);
return 0;
}