答案~ b∑d

⛴李恒旭⚔♆§  •  2年前


include <bits/stdc++.h>

using namespace std;

int main() {

int a, b, c, d, s;
cin >> a >> b >> c >> d >> s;
if (a + b == s) {
	cout << '1';
} else if (a + c == s) {
	cout << '1';
} else if (a + d == s) {
	cout << '1';
} else if (b + c == s) {
	cout << '1';
} else if (b + d == s) {
	cout << '1';
} else if (c + d == s) {
	cout << '1';
} else {
	cout << "-1";
}

return 0;

}


评论:

请先登录,才能进行评论