#include #include #include #include #include #include #include #include #include #include #include #include using namespace std; using namespace atcoder; using Graph = vector>; using ll = long long; typedef pair P_ll; typedef pair P; const ll INF_ll = 1e17; const int INF = 1e8; template bool chmax(T& a, const T& b) { if (a < b) { a = b; return 1; } return 0; } template bool chmin(T& a, const T& b) { if (b < a) { a = b; return 1; } return 0; } template using min_priority_queue = priority_queue, greater>; int main() { ll N, A, B; cin >> N >> A >> B; vector x(N); for (int i = 0; i < N; i++) { cin >> x[i]; } vector lr; dsu tree(N); vector c(N + 1, 0); for (int i = 0; i < N; i++) { int l = lower_bound(x.begin(), x.end(), x[i] + A) - x.begin(); int r = upper_bound(x.begin(), x.end(), x[i] + B) - x.begin() - 1; if (l > r) { continue; } tree.merge(i, l); c[l]++; c[r]--; } ll now = 0; for (int i = 0; i < N - 1; i++) { now += c[i]; if (now > 0) { tree.merge(i, i + 1); } } for (int i = 0; i < N; i++) { cout << tree.size(i) << endl; } return 0; }