結果

問題 No.3016 unordered_mapなるたけ落とすマン
ユーザー snteasntea
提出日時 2016-05-22 00:50:13
言語 C++11
(gcc 11.4.0)
結果
TLE  
実行時間 -
コード長 1,391 bytes
コンパイル時間 1,534 ms
コンパイル使用メモリ 166,004 KB
実行使用メモリ 13,332 KB
最終ジャッジ日時 2024-04-16 11:51:26
合計ジャッジ時間 6,174 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
10,752 KB
testcase_01 AC 2 ms
5,376 KB
testcase_02 AC 2 ms
5,376 KB
testcase_03 AC 49 ms
7,960 KB
testcase_04 AC 78 ms
7,956 KB
testcase_05 AC 81 ms
7,956 KB
testcase_06 AC 81 ms
7,956 KB
testcase_07 AC 79 ms
7,956 KB
testcase_08 AC 76 ms
7,956 KB
testcase_09 AC 85 ms
7,956 KB
testcase_10 AC 78 ms
7,952 KB
testcase_11 AC 79 ms
7,956 KB
testcase_12 AC 77 ms
7,952 KB
testcase_13 AC 76 ms
7,956 KB
testcase_14 AC 77 ms
7,952 KB
testcase_15 TLE -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
testcase_24 -- -
testcase_25 -- -
testcase_26 -- -
testcase_27 -- -
testcase_28 -- -
testcase_29 -- -
testcase_30 -- -
testcase_31 -- -
testcase_32 -- -
testcase_33 -- -
testcase_34 -- -
testcase_35 -- -
testcase_36 -- -
testcase_37 -- -
testcase_38 -- -
testcase_39 -- -
testcase_40 -- -
testcase_41 -- -
testcase_42 -- -
testcase_43 -- -
testcase_44 -- -
testcase_45 -- -
testcase_46 -- -
testcase_47 -- -
testcase_48 -- -
testcase_49 -- -
testcase_50 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

#ifdef LOCAL111
#else
	#define NDEBUG
#endif
#include <bits/stdc++.h>

using namespace std;

#define endl '\n'
#define ALL(a)  (a).begin(),(a).end()
#define SZ(a) int((a).size())
#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define RFOR(i,a,b) for (int i=(b)-1;i>=(a);i--)
#define REP(i,n)  FOR(i,0,n)
#define RREP(i,n) for (int i=(n)-1;i>=0;i--)
#define RBP(i,a) for(auto& i : a)
#ifdef LOCAL111
	#define DEBUG(x) cout<<#x<<": "<<(x)<<endl
#else
	#define DEBUG(x) true
#endif
#define F first
#define S second
#define SNP string::npos
#define WRC(hoge) cout << "Case #" << (hoge)+1 << ": "
#define INF 1e8
template<typename T> void pite(T a, T b){ for(T ite = a; ite != b; ite++) cout << (ite == a ? "" : " ") << *ite; cout << endl;}
template<typename T> bool chmax(T& a, T b){if(a < b){a = b; return true;} return false;}
template<typename T> bool chmin(T& a, T b){if(a > b){a = b; return true;} return false;}

typedef pair<int,int> P;
typedef long long int LL;
typedef unsigned long long ULL;
typedef pair<LL,LL> LP;

void ios_init(){
	//cout.setf(ios::fixed);
	//cout.precision(12);
#ifdef LOCAL111
	return;
#endif
	ios::sync_with_stdio(false); cin.tie(0);	
}

int main()
{
	ios_init();
	int n,m;
	cin >> n >> m;
	unordered_map<LL,int> mp;
	REP(i,n){
		LL a;
		cin >> a;
		mp[a]++;
	}
	vector<int> ans(m);
	REP(i,m){
		LL b;
		cin >> b;
		ans[i] = mp[b];
	}
	pite(ALL(ans));
	return 0;
}
0