結果

問題 No.632 穴埋め門松列
ユーザー 👑 Nafmo2Nafmo2
提出日時 2017-08-08 23:48:32
言語 C++14
(gcc 13.2.0 + boost 1.83.0)
結果
AC  
実行時間 2 ms / 1,000 ms
コード長 1,061 bytes
コンパイル時間 778 ms
コンパイル使用メモリ 82,236 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-04-20 05:19:09
合計ジャッジ時間 1,380 ms
ジャッジサーバーID
(参考情報)
judge3 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
5,248 KB
testcase_01 AC 2 ms
5,376 KB
testcase_02 AC 1 ms
5,376 KB
testcase_03 AC 2 ms
5,376 KB
testcase_04 AC 1 ms
5,376 KB
testcase_05 AC 2 ms
5,376 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include<iostream>
#include<cstdio>
#include<cmath>
#include<cstring>
#include<string>
#include<stack>
#include<queue>
#include<vector>
#include<algorithm>
#include<iomanip>
#include<cassert>

typedef long long int ll;
using namespace std;
#define FOR(i,a,b) for (int i=(a);i<(b);i++)
#define REP(i,n) for (int i=0;i<(n);i++)
#define EREP(i,n) for (int i=1;i<=(n);i++)
const int MOD = 1000000007;
const int INF = 1000000;
//#define EVEL 1
#ifdef EVEL
#define DEB(X) cout << #X << ":" <<X<<" " ;
#define TF(f) f ? cout<<"true  " : cout<<"false ";
#define END cout<<"\n";
#else
#define DEB(X) {X=X;}
#define TF(f) {f=f;}
#define END {}
#endif

    string S;
    int A[3],B;

int main(){
    ios::sync_with_stdio(false);
    REP(i,3){
        cin>>S;
        if(S=="?"){B=i;}
        else A[i]=S[0]-'0';
    }
    DEB(A[0])DEB(A[1])DEB(A[2])END
    DEB(B)
    if(B==0){
        if(A[1]<A[2])cout<<"4";
        else cout<<"1";
    }
    if(B==1){
        cout<<"14";
    }
    if(B==2){
        if(A[0]>A[1])cout<<"4";
        else cout<<"1";
    }
    return 0;
}
0