結果

問題 No.1795 AtCoder Heuristic Rating coloring
ユーザー SSRSSSRS
提出日時 2021-12-24 00:01:02
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 342 ms / 2,000 ms
コード長 372 bytes
コンパイル時間 2,517 ms
コンパイル使用メモリ 210,052 KB
実行使用メモリ 14,544 KB
最終ジャッジ日時 2023-10-20 07:40:46
合計ジャッジ時間 9,896 ms
ジャッジサーバーID
(参考情報)
judge14 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,348 KB
testcase_01 AC 2 ms
4,348 KB
testcase_02 AC 2 ms
4,348 KB
testcase_03 AC 2 ms
4,348 KB
testcase_04 AC 6 ms
4,348 KB
testcase_05 AC 6 ms
4,348 KB
testcase_06 AC 7 ms
4,348 KB
testcase_07 AC 7 ms
4,348 KB
testcase_08 AC 8 ms
4,348 KB
testcase_09 AC 8 ms
4,348 KB
testcase_10 AC 8 ms
4,348 KB
testcase_11 AC 8 ms
4,348 KB
testcase_12 AC 2 ms
4,348 KB
testcase_13 AC 2 ms
4,348 KB
testcase_14 AC 2 ms
4,348 KB
testcase_15 AC 2 ms
4,348 KB
testcase_16 AC 2 ms
4,348 KB
testcase_17 AC 2 ms
4,348 KB
testcase_18 AC 2 ms
4,348 KB
testcase_19 AC 2 ms
4,348 KB
testcase_20 AC 2 ms
4,348 KB
testcase_21 AC 2 ms
4,348 KB
testcase_22 AC 2 ms
4,348 KB
testcase_23 AC 2 ms
4,348 KB
testcase_24 AC 2 ms
4,348 KB
testcase_25 AC 2 ms
4,348 KB
testcase_26 AC 2 ms
4,348 KB
testcase_27 AC 2 ms
4,348 KB
testcase_28 AC 2 ms
4,348 KB
testcase_29 AC 2 ms
4,348 KB
testcase_30 AC 2 ms
4,348 KB
testcase_31 AC 2 ms
4,348 KB
testcase_32 AC 113 ms
6,556 KB
testcase_33 AC 79 ms
5,984 KB
testcase_34 AC 165 ms
7,668 KB
testcase_35 AC 142 ms
7,164 KB
testcase_36 AC 171 ms
7,996 KB
testcase_37 AC 92 ms
6,172 KB
testcase_38 AC 91 ms
6,316 KB
testcase_39 AC 183 ms
8,000 KB
testcase_40 AC 124 ms
6,864 KB
testcase_41 AC 170 ms
7,700 KB
testcase_42 AC 110 ms
6,588 KB
testcase_43 AC 120 ms
7,004 KB
testcase_44 AC 152 ms
7,736 KB
testcase_45 AC 111 ms
6,604 KB
testcase_46 AC 190 ms
8,260 KB
testcase_47 AC 49 ms
5,016 KB
testcase_48 AC 111 ms
6,800 KB
testcase_49 AC 199 ms
8,352 KB
testcase_50 AC 102 ms
6,232 KB
testcase_51 AC 91 ms
6,068 KB
testcase_52 AC 256 ms
10,732 KB
testcase_53 AC 257 ms
10,708 KB
testcase_54 AC 342 ms
14,544 KB
testcase_55 AC 336 ms
14,544 KB
testcase_56 AC 333 ms
14,544 KB
testcase_57 AC 330 ms
14,544 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;
int main(){
  int N, M;
  cin >> N >> M;
  map<string, int> mp;
  for (int i = 0; i < N; i++){
    string S;
    int A;
    cin >> S >> A;
    mp[S] = A;
  }
  for (int i = 0; i < M; i++){
    string T;
    int B;
    cin >> T >> B;
    mp[T] = B;
  }
  for (auto P : mp){
    cout << P.first << ' ' << P.second << endl;
  }
}
0