結果

問題 No.1110 好きな歌
コンテスト
ユーザー trineutron
提出日時 2019-10-22 11:33:43
言語 C++17(clang)
(clang++ 23.1.3 + boost 1.92.0 + ACL)
コンパイル:
clang++ -O2 -lm -std=c++1z -Wuninitialized -DONLINE_JUDGE -o a.out _filename_
実行:
./a.out
結果
TLE  
実行時間 -
コード長 398 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 1,614 ms
コンパイル使用メモリ 166,184 KB
実行使用メモリ 9,908 KB
最終ジャッジ日時 2026-10-02 16:47:08
合計ジャッジ時間 108,817 ms
ジャッジサーバーID
(参考情報)
judge1_0 / judge4_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 40 TLE * 11
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

#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