0
已解决
张灵
高级守护
高级守护
#include <iostream>
#include <cstdio>
using namespace std;
int main(){
freopen("5565.in","r",stdin);
freopen("5565.out","w",stdout);
int a,b,c;
scanf("%d:%d:%d",&a,&b,&c);
if(a>12){
if(a<24)a-=12;
if(a==24)a=0;
}
printf("%02d:%02d:%02d",a,b,c);
fclose(stdin);
fclose(stdout);
return 0;
}
请问5565错在哪?