結果

問題 No.1032 数数え
ユーザー trineutrontrineutron
提出日時 2020-04-23 14:01:56
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
RE  
実行時間 -
コード長 302 bytes
コンパイル時間 1,894 ms
コンパイル使用メモリ 195,600 KB
実行使用メモリ 6,948 KB
最終ジャッジ日時 2024-04-21 14:11:10
合計ジャッジ時間 4,234 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 RE -
testcase_01 RE -
testcase_02 RE -
testcase_03 RE -
testcase_04 AC 2 ms
5,376 KB
testcase_05 RE -
testcase_06 RE -
testcase_07 AC 314 ms
5,376 KB
testcase_08 RE -
testcase_09 AC 14 ms
5,376 KB
testcase_10 AC 1 ms
5,376 KB
testcase_11 RE -
testcase_12 AC 296 ms
5,376 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
using namespace std;

int main() {
    int n, m;
    cin >> n >> m;
    vector<int> v(m);
    for (int i = 0; i < n; i++) {
        int l;
        cin >> l;
        v.at(l - 1)++;
    }
    for (int i = 0; i < m; i++) {
        cout << i + 1 << " " << v.at(i) << endl;
    }
}
0