結果

問題 No.8016 unordered_mapなるたけ落とすマン
ユーザー はむ吉🐹
提出日時 2016-05-26 12:05:09
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
WA  
実行時間 -
コード長 546 bytes
コンパイル時間 793 ms
コンパイル使用メモリ 68,084 KB
実行使用メモリ 9,728 KB
最終ジャッジ日時 2024-10-07 15:42:09
合計ジャッジ時間 6,069 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 2 WA * 1
other AC * 29 WA * 19
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <cstdlib>
#include <iostream>
#include <map>


int main() {
    std::cin.tie(nullptr);
    std::ios::sync_with_stdio(false);
    int n, m;
    std::cin >> n >> m;
    std::map<long long, int> table;
    long long a;
    for (auto i = 0; i < n; i++)
    {
        std::cin >> a;
        table[a]++;
    }
    int b;
    for (auto j = 0; j < m; j++)
    {
        std::cin >> b;
        if (j > 0)
        {
            std::cout << " ";
        }
        std::cout << table[b];
    }
    std::cout << std::endl;
    return EXIT_SUCCESS;
}
0