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