Run ID:110111
提交时间:2025-02-14 18:04:43
#include <iostream> using namespace std; int main() { int M; cin >> M; // 输入拉动开关的次数 // 判断奇偶性 if (M % 2 == 1) { cout << 1 << endl; // 奇数次,灯点亮 } else { cout << 0 << endl; // 偶数次,灯熄灭 } return 0; }