80分求救。。。。
查看原帖
80分求救。。。。
1358655
yexiawuzhi楼主2024/5/20 00:51
#include<iostream>
using namespace std;
int main() {
	int x;
	cin >> x;
	if ((x % 2 == 0) &&( x > 4 && x <= 12)) {
		cout << "1 " ;
	}
	else {
		cout << "0 " ;
	}
	
	if (x % 2 == 0 || (x > 4 && x <= 12)) {
		cout << "1 " ;
	}
	else {
		cout << "0 " ;
	}
	
	if ((x % 2 == 0 ^(x > 4 && x <= 12))) {
		cout << "1 " ;
	}
	else {
		cout << "0 " ;
	}

	if (x % 2 != 0 || (x <= 4 || x > 12)) {
		cout << "1" ;
	}
	else {
		cout << "0" ;
	}
	system("pause");
	return 0;
}
2024/5/20 00:51
加载中...