結果
| 問題 |
No.1032 数数え
|
| ユーザー |
|
| 提出日時 | 2021-03-05 20:42:32 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 512 bytes |
| コンパイル時間 | 889 ms |
| コンパイル使用メモリ | 74,456 KB |
| 実行使用メモリ | 13,636 KB |
| 最終ジャッジ日時 | 2024-10-06 23:13:56 |
| 合計ジャッジ時間 | 4,424 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 4 TLE * 1 -- * 5 |
ソースコード
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main(){
int n,m;
cin >> n >> m;
vector<int> l(n);
for(int i=0; i<n; i++){
cin >> l[i];
}
sort(l.begin(),l.end());
int cnt = 0;
for(int i=1; i<=m; i++){
for(int j=0; j<n; j++){
if(i < l[j]){
break;
}
if(i == l[j]){
cnt++;
}
}
cout << i << ' ' << cnt << endl;
cnt = 0;
}
}