結果

問題 No.524 コインゲーム
ユーザー olpheolphe
提出日時 2017-06-02 22:59:11
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
TLE  
実行時間 -
コード長 976 bytes
コンパイル時間 835 ms
コンパイル使用メモリ 110,804 KB
実行使用メモリ 4,348 KB
最終ジャッジ日時 2023-10-21 22:25:51
合計ジャッジ時間 8,458 ms
ジャッジサーバーID
(参考情報)
judge12 / judge9
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,348 KB
testcase_01 AC 2 ms
4,348 KB
testcase_02 AC 412 ms
4,348 KB
testcase_03 AC 258 ms
4,348 KB
testcase_04 TLE -
testcase_05 AC 2 ms
4,348 KB
testcase_06 AC 1 ms
4,348 KB
testcase_07 AC 331 ms
4,348 KB
testcase_08 AC 200 ms
4,348 KB
testcase_09 AC 194 ms
4,348 KB
testcase_10 AC 101 ms
4,348 KB
testcase_11 AC 2 ms
4,348 KB
testcase_12 AC 3 ms
4,348 KB
testcase_13 AC 2 ms
4,348 KB
testcase_14 AC 2 ms
4,348 KB
testcase_15 AC 2 ms
4,348 KB
testcase_16 AC 1 ms
4,348 KB
testcase_17 AC 5 ms
4,348 KB
testcase_18 AC 3 ms
4,348 KB
testcase_19 AC 2 ms
4,348 KB
testcase_20 AC 4 ms
4,348 KB
testcase_21 AC 5 ms
4,348 KB
testcase_22 AC 5 ms
4,348 KB
testcase_23 AC 2 ms
4,348 KB
testcase_24 AC 14 ms
4,348 KB
testcase_25 AC 30 ms
4,348 KB
testcase_26 TLE -
testcase_27 TLE -
testcase_28 AC 350 ms
4,348 KB
testcase_29 AC 73 ms
4,348 KB
testcase_30 AC 391 ms
4,348 KB
testcase_31 AC 134 ms
4,348 KB
testcase_32 AC 2 ms
4,348 KB
testcase_33 AC 2 ms
4,348 KB
testcase_34 AC 12 ms
4,348 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include "iostream"
#include "climits"
#include "list"
#include "queue"
#include "stack"
#include "set"
#include "functional"
#include "algorithm"
#include "math.h"
#include "utility"
#include "string"
#include "map"
#include "unordered_map"
#include "iomanip"
#include "random"

using namespace std;
const long long int MOD = 1000000007;
list<long long int> Prime(int M) {
	list<long long int>P;
	P.push_back(2);
	P.push_back(3);
	for (int i = 5; i <= M; i += 6) {
		bool flag = true;
		for (auto j : P) {
			if (i%j == 0) {
				flag = false;
				break;
			}
		}
		if (flag)P.push_back(i);
		flag = true;
		for (auto j : P) {
			if ((i + 2) % j == 0) {
				flag = false;
				break;
			}
		}
		if (flag)P.push_back(i + 2);
	}
	return P;
}


long long int N;
long long int ans;
long long int H, W;

long long int K;

int main() {
	ios::sync_with_stdio(false);
	cin >> N;
	for (long long int i = 1; i <= N; i++) {
		ans ^= i;
	}
	if (ans==0)cout << "X\n";
	else cout << "O\n";
}
0