https://pintia.cn/problem-sets/994805260223102976/problems/994805295203598336
#include<iostream>
#include<bits/stdc++.h>
using namespace std;
int main()
{
double a,b;
cin>>a>>b;
int c=round((b-a)/100);
int h=c/3600;
int m=c%3600/60;
int s=c%60;
printf("%02d:%02d:%02d",h,m,s);
return 0;
}
PAT乙级1026程序运行时间(秒数转换为时间)(值得学习)
最新推荐文章于 2024-07-03 17:31:11 发布