Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int a, b, c, d;
- cin >> a >> b >> c >> d;
- int r = a + b + c;
- int kolku = 0;
- if(r % 2 == 0) {
- kolku += 1;
- }
- r = a + b + d;
- if(r % 2 == 0) {
- kolku += 1;
- }
- r = a + c + d;
- if(r % 2 == 0) {
- kolku += 1;
- }
- r = b + c + d;
- if(r % 2 == 0) {
- kolku += 1;
- }
- if(kolku == 1) {
- cout << "+" << endl;
- }
- else if(kolku > 1) {
- cout << "?" << endl;
- }
- else {
- cout << "-" << endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement