結果
問題 |
No.8016 unordered_mapなるたけ落とすマン
|
ユーザー |
![]() |
提出日時 | 2020-07-18 07:35:17 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 97 ms / 1,000 ms |
コード長 | 349 bytes |
コンパイル時間 | 1,920 ms |
コンパイル使用メモリ | 198,452 KB |
最終ジャッジ日時 | 2025-01-12 00:05:21 |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 48 |
ソースコード
#include <bits/stdc++.h> using namespace std; int main() { cin.tie(nullptr); ios::sync_with_stdio(false); int N, M; cin >> N >> M; map<long, int> MA; for (int i = 0; i < N; i++) { long A; cin >> A; MA[A]++; } for (int i = 0; i < M; i++) { long B; cin >> B; cout << MA[B] << ((i == M - 1) ? "\n" : " "); } }