結果

問題 No.2619 Sorted Nim
ユーザー umimelumimel
提出日時 2024-01-27 02:41:26
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
WA  
実行時間 -
コード長 1,116 bytes
コンパイル時間 1,795 ms
コンパイル使用メモリ 168,804 KB
実行使用メモリ 6,548 KB
最終ジャッジ日時 2024-01-27 02:41:32
合計ジャッジ時間 5,560 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
6,548 KB
testcase_01 AC 2 ms
6,548 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 AC 22 ms
6,548 KB
testcase_05 AC 21 ms
6,548 KB
testcase_06 AC 25 ms
6,548 KB
testcase_07 WA -
testcase_08 AC 24 ms
6,548 KB
testcase_09 AC 2 ms
6,548 KB
testcase_10 AC 24 ms
6,548 KB
testcase_11 WA -
testcase_12 AC 23 ms
6,548 KB
testcase_13 WA -
testcase_14 AC 24 ms
6,548 KB
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 AC 24 ms
6,548 KB
testcase_19 AC 20 ms
6,548 KB
testcase_20 AC 20 ms
6,548 KB
testcase_21 AC 25 ms
6,548 KB
testcase_22 AC 21 ms
6,548 KB
testcase_23 WA -
testcase_24 WA -
testcase_25 AC 23 ms
6,548 KB
testcase_26 WA -
testcase_27 AC 20 ms
6,548 KB
testcase_28 AC 25 ms
6,548 KB
testcase_29 AC 24 ms
6,548 KB
testcase_30 AC 22 ms
6,548 KB
testcase_31 AC 2 ms
6,548 KB
testcase_32 WA -
testcase_33 AC 21 ms
6,548 KB
testcase_34 AC 20 ms
6,548 KB
testcase_35 AC 22 ms
6,548 KB
testcase_36 AC 24 ms
6,548 KB
testcase_37 WA -
testcase_38 WA -
testcase_39 AC 24 ms
6,548 KB
testcase_40 AC 21 ms
6,548 KB
testcase_41 WA -
testcase_42 AC 20 ms
6,548 KB
testcase_43 WA -
testcase_44 WA -
testcase_45 WA -
testcase_46 AC 22 ms
6,548 KB
testcase_47 WA -
testcase_48 AC 2 ms
6,548 KB
testcase_49 WA -
testcase_50 WA -
testcase_51 AC 22 ms
6,548 KB
testcase_52 AC 2 ms
6,548 KB
testcase_53 AC 25 ms
6,548 KB
testcase_54 AC 21 ms
6,548 KB
testcase_55 WA -
testcase_56 WA -
testcase_57 WA -
testcase_58 WA -
testcase_59 WA -
testcase_60 AC 21 ms
6,548 KB
testcase_61 AC 21 ms
6,548 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<bits/stdc++.h>
using namespace std;
using ll = long long;
using pll = pair<ll, ll>;
#define drep(i, cc, n) for (ll i = (cc); i <= (n); ++i)
#define rep(i, n) drep(i, 0, n - 1)
#define all(a) (a).begin(), (a).end()
#define pb push_back
#define fi first
#define se second
mt19937_64 rng(chrono::system_clock::now().time_since_epoch().count());
const ll MOD1000000007 = 1000000007;
const ll MOD998244353 = 998244353;
const ll MOD[3] = {999727999, 1070777777, 1000000007};
const ll LINF = 1LL << 60LL;
const int IINF = (1 << 30) - 1;


void solve(){
    int n; cin >> n;
    vector<int> a(n);
    for(int i=0; i<n; i++) cin >> a[i];
    
    if(n==1){
        cout << "First\n";
        return;
    }

    if(n%2==0){
        if(a[n-2] < a[n-1]){
            cout << "First\n";
        }else{
            cout << "Second\n";
        }
    }
    if(n%2==1){
        if(a[n-2] == a[n-1]){
            cout << "First\n";
        }else{
            cout << "Second\n";
        }
    }
}

int main(){
    cin.tie(nullptr);
    ios::sync_with_stdio(false);
    
    int T=1;
    //cin >> T;
    while(T--) solve();
}
0