結果

問題 No.1110 好きな歌
ユーザー trineutron
提出日時 2019-10-22 11:33:43
言語 C++17(clang)
(17.0.6 + boost 1.87.0)
結果
TLE  
実行時間 -
コード長 398 bytes
コンパイル時間 2,195 ms
コンパイル使用メモリ 163,980 KB
実行使用メモリ 10,788 KB
最終ジャッジ日時 2024-11-30 15:20:35
合計ジャッジ時間 134,230 ms
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 34 TLE * 17
権限があれば一括ダウンロードができます

ソースコード

diff #

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

int main() {
    cin.tie(0);
    ios::sync_with_stdio(false);
    int n, d;
    cin >> n >> d;
    vector<int> a(n);
    for (int i = 0; i < n; i++) cin >> a.at(i);
    for (int i = 0; i < n; i++) {
        int ans = 0;
        for (int j = 0; j < n; j++) {
            if (a.at(i) - a.at(j) >= d) ans++;
        }
        cout << ans << "\n";
    }
}
0