#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:1000000000")
using ll = long long;
using ld = long double;
using namespace std;
const int MAXN = 100200;
const int INF = 1000 * 1000;
int c[MAXN];
int a, b, h, w, n;
ll f[MAXN];
ll f2[MAXN];
int solve(int x, int y) {
  memset(f, 0, sizeof(f));
  f[1] = 1;
  if ((x == 1) && (y == 1)) return 0;
  for (int k = 0; k < n; k++) {
    memcpy(f2, f, sizeof(f));
    for (int l = 0; l < MAXN; l++) {
      int i1 = min(ll(MAXN - 1), f[l] * c[k]);
      f2[l] = max(f2[l], f[l] * c[k]);
      f2[i1] = max(f2[i1], ll(l));
      int id = min(f[l], ll(MAXN - 1));
      int id2 = min(ll(MAXN - 1), (ll)c[k] * l);
      f2[id] = max(f2[id], ll(id2));
      f2[id2] = max(f2[id2], ll(id));
    }
    memcpy(f, f2, sizeof(f));
    for (int l = MAXN - 1; l > 0; l--) f[l - 1] = max(f[l - 1], f[l]);
    if (f[x] >= y) return k + 1;
  }
  return n + 1;
}
int g(int x, int y) { return ((x - 1) / y + 1); }
int main() {
  ios_base::sync_with_stdio(0);
  cout.setf(ios::fixed);
  cout.precision(20);
  cin >> a >> b >> h >> w >> n;
  for (int i = 0; i < n; i++) cin >> c[i];
  sort(c, c + n);
  reverse(c, c + n);
  int ans = min(solve(g(a, h), g(b, w)), solve(g(a, w), g(b, h)));
  if (ans <= n)
    cout << ans << endl;
  else
    cout << -1 << endl;
  return 0;
}
