#include <iostream>

using namespace std;

int N, A, B, C, D;
int dp[101001];

int main() {

    cin >> N >> A >> B >> C;

    fill(dp, dp + 101001, 0);
    dp[A] = C;

    for (int i = 0; i < N; i++) {
        cin >> D;
        for (int j = A + B * N; j >= A; j--) {
            if (dp[j])
                dp[j + B] = max(dp[j + B], dp[j] + D);
        }
    }

    int ans = 0;
    for (int i = A; i <= A + B * N; i++) {
        ans = max(ans, dp[i] / i);
    }
    cout << ans << endl;
}
