結果

問題 No.2016 Countdown Divisors
ユーザー erbowlerbowl
提出日時 2022-08-07 15:43:22
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 231 ms / 2,000 ms
コード長 472 bytes
コンパイル時間 2,234 ms
コンパイル使用メモリ 209,588 KB
実行使用メモリ 9,940 KB
最終ジャッジ日時 2023-10-17 10:44:23
合計ジャッジ時間 8,247 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,348 KB
testcase_01 AC 172 ms
4,348 KB
testcase_02 AC 176 ms
4,348 KB
testcase_03 AC 231 ms
9,372 KB
testcase_04 AC 195 ms
8,688 KB
testcase_05 AC 184 ms
8,480 KB
testcase_06 AC 63 ms
5,412 KB
testcase_07 AC 61 ms
5,396 KB
testcase_08 AC 206 ms
9,940 KB
testcase_09 AC 208 ms
9,940 KB
testcase_10 AC 205 ms
9,940 KB
testcase_11 AC 208 ms
9,940 KB
testcase_12 AC 207 ms
9,940 KB
testcase_13 AC 149 ms
4,348 KB
testcase_14 AC 143 ms
4,348 KB
testcase_15 AC 140 ms
4,348 KB
testcase_16 AC 190 ms
6,708 KB
testcase_17 AC 179 ms
6,556 KB
testcase_18 AC 185 ms
6,624 KB
testcase_19 AC 2 ms
4,348 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

typedef long long ll;
typedef long double ld;
#include <bits/stdc++.h>
using namespace std;
#define int long long

signed main(){
    ll n;
    std::cin >> n;
    map<ll,bool> m;
    m[1]=true;
    m[3]=true;
    m[4]=true;
    m[5]=true;
    m[7]=true;
    m[8]=true;
    for (int i = 0; i < n; i++) {
        ll t;
        std::cin >> t;
        if(m[t]){
            std::cout << 1 << std::endl;
        }else{
            std::cout << 2 << std::endl;
        }
    }
}
0