求助
查看原帖
求助
349755
Quit楼主2021/4/5 17:25

#include<bits/stdc++.h>
using namespace std;
int a,b,c,d,beg,end,ave,hour,minu;
char ch;
int main(){
	cin>>a>>ch>>b>>c>>ch>>d;
	beg=a*60+b;
	end=c*60+d;
	ave=(beg+end)/2;
	hour=ave/60;
	minu=ave%60;
	if(hour>=10) cout<<hour;
	else cout<<0<<hour;
	cout<<":";
	if(minu>=10) cout<<minu;
	else cout<<0<<minu;
	return 0;
}

代码如上,求助为什么会CE,本地跑过没问题

2021/4/5 17:25
加载中...