import sys # sys.setrecursionlimit(200005) # sys.set_int_max_str_digits(200005) int1 = lambda x: int(x)-1 pDB = lambda *x: print(*x, end="\n", file=sys.stderr) p2D = lambda x: print(*x, sep="\n", end="\n\n", file=sys.stderr) def II(): return int(sys.stdin.readline()) def LI(): return list(map(int, sys.stdin.readline().split())) def LLI(rows_number): return [LI() for _ in range(rows_number)] def LI1(): return list(map(int1, sys.stdin.readline().split())) def LLI1(rows_number): return [LI1() for _ in range(rows_number)] def SI(): return sys.stdin.readline().rstrip() dij = [(0, 1), (-1, 0), (0, -1), (1, 0)] # dij = [(0, 1), (-1, 0), (0, -1), (1, 0), (1, 1), (1, -1), (-1, 1), (-1, -1)] # inf = -1-(-1 << 31) inf = -1-(-1 << 63) # md = 10**9+7 md = 998244353 def f(pos): arr = [0]*z+pos if not arr: return 0 n = len(arr) i = 0 while i+1 < n and arr[i]*arr[i+1] < l: i += 1 j = n-1 while j-1 >= 0 and arr[j]*arr[j-1] > r: j -= 1 return max(j-i+1, 1) n, l, r = LI() aa = LI() pos = [] neg = [] z = 0 for a in aa: if a < 0: neg.append(a) elif a > 0: pos.append(a) else: z += 1 pos.sort() neg.sort(reverse=True) # pos[2,3,5,6] # neg[-1,-2,-4,-5,-7] if r < 0: for a in pos: for b in neg: if l <= a*b <= r: print(2) exit() ans = 1 elif l >= 0 or not neg or not pos: ans = max(f(pos), f(neg)) else: n, m = len(pos), len(neg) j = m-1 ans = max(f(pos), f(neg)) for i in range(n-1): if i and pos[i-1]*pos[i] > r: break while j-1 >= 0 and neg[j]*neg[j-1] > r or j >= 0 and neg[j]*pos[i] < l: j -= 1 if j < 0: break ans = max(i+1+j+1+z) print(ans)