#include using namespace std; using ll = long long; int main () { int N; ll L, R; cin >> N >> L >> R; ll A[5050]; for (int i = 0; i < N; i ++) cin >> A[i]; sort(A, A + N); int ans = 1; for (int l = 0; l < N - 1; l ++) { for (int r = l + 1; r <= N; r ++) { if (r == N) { ans = max(ans, N - l); /*for (int p = l; p < r; p ++) { cout << A[p] << " "; } cout << endl;*/ continue; } ll x = A[r] * A[r- 1], y = A[r] * A[l]; bool ok = L <= min(x, y) && max(x, y) <= R; if (!ok) { ans = max(ans, r - l); break; } } } cout << ans << endl; }