結果

問題 No.3060 サンプルケース至上主義
ユーザー qLethonqLethon
提出日時 2020-04-01 21:43:05
言語 C++17
(gcc 13.2.0 + boost 1.83.0)
結果
AC  
実行時間 2 ms / 2,000 ms
コード長 958 bytes
コンパイル時間 2,086 ms
コンパイル使用メモリ 197,504 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-09-09 17:29:30
合計ジャッジ時間 2,376 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ(β)

テストケース

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

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

template<class INT>
std::vector<INT> get_min_prime_fact_table(INT n){
    std::vector<INT> lp(n + 1), P;
    for (INT i = 2; i <= n; i++){
        if (lp[i] == 0){
            lp[i] = i;
            P.push_back(i);
        }
        for (INT j = 0; j <= P.size() and P[j] <= lp[i] and i * P[j] <= n; j++)
            lp[i * P[j]] = P[j];
    }

    return lp;
}

template<class INT>
std::map<INT, int> prime_factorize(INT n, std::vector<INT>& lp){
    std::map<INT, int> res;
    while (n != 1){
        res[lp[n]]++;
        n /= lp[n];
    }

    return res;
}

int main(){
    string S;
    cin >> S;

    if (S == "0")
        puts("Nothing");
    else if (S == "3.14159265")
        puts("pi");
    else if (S == "1112345678999+X"){
        puts("九蓮宝燈");
        puts("Thirteen Orphans");
    } else if (S == "All")
        printf("3\n4\n4\n3\n6\n2\n2\n");
    else
        puts("さmpぇ");

}
0