#define _CRT_SECURE_NO_WARNINGS #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include using namespace std; #define MAX_MOD 1000000007 #define REP(i,n) for(long long i = 0;i < n;++i) #define LONG_INF 100000000000000 int main() { long long n; cin >> n; vector d; REP(i, n) { long long tmp; cin >> tmp; d.push_back(tmp); } long long x, y; cin >> x >> y; if (x > y) swap(x, y); long long ans = LONG_INF; for (int i = 0;i < n;++i) { int tmp = 0; if (x % d[i] != 0)tmp++; ans = min(ans,(x / d[i])+tmp); } cout << ans << endl; return 0; }