WA #4 求调
查看原帖
WA #4 求调
380639
dthythxth_Huge_Brain楼主2023/8/18 10:27
#include<bits/stdc++.h>
using namespace std;
#define int long long
int a,b,c,d,c1,c2,c3;
signed main(){
	ios::sync_with_stdio(0);cin.tie(0);cout.tie(0);
	//freopen(".in","r",stdin);
	//freopen(".out","w",stdout);
	cin>>a>>b>>c>>d;
	c1=max(a,d);
	c2=max(b,d);
	c3=max(c,d);
	if(a*2>=c1&&b*2>=c2&&c*2>=c3&&d*2>=c3){
		cout<<c1<<'\n'<<c2<<'\n'<<c3;
	}
	else cout<<-1;
	return 0;
}

输入:99 50 25 49

输出:

99
50
49

好像没问题啊。。。

2023/8/18 10:27
加载中...