結果

問題 No.201 yukicoderじゃんけん
ユーザー firiexpfiriexp
提出日時 2018-12-29 13:23:36
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
CE  
(最新)
AC  
(最初)
実行時間 -
コード長 746 bytes
コンパイル時間 618 ms
コンパイル使用メモリ 74,376 KB
最終ジャッジ日時 2024-04-27 02:45:48
合計ジャッジ時間 1,015 ms
ジャッジサーバーID
(参考情報)
judge4 / judge5
このコードへのチャレンジ
(要ログイン)
コンパイルエラー時のメッセージ・ソースコードは、提出者また管理者しか表示できないようにしております。(リジャッジ後のコンパイルエラーは公開されます)
ただし、clay言語の場合は開発者のデバッグのため、公開されます。

コンパイルメッセージ
main.cpp: In function 'int main()':
main.cpp:21:23: error: variable 'std::array<int, 10010> v' has initializer but incomplete type
   21 |     array<int, 10010> v{}, v2{};
      |                       ^
main.cpp:21:28: error: variable 'std::array<int, 10010> v2' has initializer but incomplete type
   21 |     array<int, 10010> v{}, v2{};
      |                            ^~

ソースコード

diff #

#include <iostream>
#include <algorithm>
#include <vector>
#include <iomanip>
#include <map>
#include <queue>
#include <limits>

static const int MOD = 1000000007;
using ll = long long;
using u32 = unsigned;
using namespace std;

template<class T>
constexpr T INF = ::numeric_limits<T>::max() / 32 * 15 + 208;

int main() {
    string s, t, p1, p2, x1, x2;
    cin >> s >> p1 >> x1;
    cin >> t >> p2 >> x2;
    array<int, 10010> v{}, v2{};
    for (int i = 0; i < p1.size(); ++i) {
        v[10010-p1.size()+i] = p1[i] - '0';
    }
    for (int i = 0; i < p2.size(); ++i) {
        v2[10010-p2.size()+i] = p2[i] - '0';
    }
    if(v > v2) cout << s << "\n";
    else if (v < v2) cout << t << "\n";
    else cout << -1 << "\n";
    return 0;
}
0