結果

問題 No.3016 unordered_mapなるたけ落とすマン
ユーザー zeosuttzeosutt
提出日時 2016-05-20 14:17:07
言語 C++11
(gcc 11.4.0)
結果
AC  
実行時間 255 ms / 1,000 ms
コード長 390 bytes
コンパイル時間 592 ms
コンパイル使用メモリ 64,996 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-04-16 11:25:53
合計ジャッジ時間 13,234 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
6,816 KB
testcase_01 AC 2 ms
6,944 KB
testcase_02 AC 1 ms
6,940 KB
testcase_03 AC 234 ms
6,940 KB
testcase_04 AC 255 ms
6,940 KB
testcase_05 AC 250 ms
6,944 KB
testcase_06 AC 250 ms
6,944 KB
testcase_07 AC 250 ms
6,944 KB
testcase_08 AC 251 ms
6,940 KB
testcase_09 AC 246 ms
6,944 KB
testcase_10 AC 254 ms
6,944 KB
testcase_11 AC 249 ms
6,940 KB
testcase_12 AC 243 ms
6,944 KB
testcase_13 AC 252 ms
6,944 KB
testcase_14 AC 243 ms
6,944 KB
testcase_15 AC 241 ms
6,944 KB
testcase_16 AC 243 ms
6,940 KB
testcase_17 AC 247 ms
6,940 KB
testcase_18 AC 243 ms
6,940 KB
testcase_19 AC 239 ms
6,944 KB
testcase_20 AC 236 ms
6,944 KB
testcase_21 AC 239 ms
6,944 KB
testcase_22 AC 236 ms
6,944 KB
testcase_23 AC 238 ms
6,944 KB
testcase_24 AC 234 ms
6,940 KB
testcase_25 AC 234 ms
6,944 KB
testcase_26 AC 230 ms
6,944 KB
testcase_27 AC 238 ms
6,940 KB
testcase_28 AC 232 ms
6,944 KB
testcase_29 AC 233 ms
6,944 KB
testcase_30 AC 228 ms
6,940 KB
testcase_31 AC 227 ms
6,944 KB
testcase_32 AC 232 ms
6,944 KB
testcase_33 AC 225 ms
6,944 KB
testcase_34 AC 229 ms
6,940 KB
testcase_35 AC 224 ms
6,940 KB
testcase_36 AC 224 ms
6,940 KB
testcase_37 AC 229 ms
6,940 KB
testcase_38 AC 221 ms
6,944 KB
testcase_39 AC 226 ms
6,944 KB
testcase_40 AC 221 ms
6,944 KB
testcase_41 AC 2 ms
6,940 KB
testcase_42 AC 2 ms
6,944 KB
testcase_43 AC 2 ms
6,940 KB
testcase_44 AC 21 ms
6,940 KB
testcase_45 AC 19 ms
6,940 KB
testcase_46 AC 20 ms
6,944 KB
testcase_47 AC 206 ms
6,940 KB
testcase_48 AC 195 ms
6,940 KB
testcase_49 AC 206 ms
6,940 KB
testcase_50 AC 245 ms
6,940 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <algorithm>
#include <iostream>
#include <vector>

using namespace std;

int main() {
	int n, m;
	vector<long long> v;

	cin >> n >> m;
	while (n--) {
		long long a;
		cin >> a;
		v.push_back(a);
	}
	sort(v.begin(), v.end());
	while (m--) {
		long long b;
		cin >> b;
		cout << upper_bound(v.begin(), v.end(), b) - lower_bound(v.begin(), v.end(), b) << " \n"[!m];
	}

	return 0;
}
0