結果
| 問題 | No.2619 Sorted Nim |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-01-27 03:21:44 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.90.0) |
| 結果 |
AC
|
| 実行時間 | 52 ms / 2,000 ms |
| コード長 | 311 bytes |
| 記録 | |
| コンパイル時間 | 1,311 ms |
| コンパイル使用メモリ | 212,164 KB |
| 実行使用メモリ | 6,528 KB |
| 最終ジャッジ日時 | 2026-07-03 12:49:56 |
| 合計ジャッジ時間 | 6,082 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 62 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
int main () {
int N;
cin >> N;
std::vector<int> A(N);
for (auto& a : A) {
cin >> a;
}
for (int i = N - 1; i; i --) {
A[i] -= A[i - 1];
}
int ans = 0;
for (int i = N - 1; i >= 0; i -= 2) {
ans ^= A[i];
}
cout << (ans ? "First" : "Second") << endl;
}