#include <bits/stdc++.h>
#pragma GCC optimize("O3")
using namespace std;
int add(int a, int b) {
  long long x = a + b;
  if (x >= 1000000007) x -= 1000000007;
  if (x < 0) x += 1000000007;
  return x;
}
long long mul(long long a, long long b) { return (a * b) % 1000000007; }
long long pw(long long a, long long b) {
  long long ans = 1;
  while (b) {
    if (b & 1) ans = (ans * a) % 1000000007;
    a = (a * a) % 1000000007;
    b >>= 1;
  }
  return ans;
}
long long v[100002];
map<pair<long long, pair<long long, long long> >, int> mp;
int getAns(long long a, long long b, long long h, long long w, long long n) {
  mp.clear();
  if (h >= a && w >= b) {
    return 0;
  } else {
    if (h >= a) {
      int ans = 0;
      while (n && w < b) w *= v[n], --n, ++ans;
      if (w >= b)
        return ans;
      else
        return -1;
    } else {
      if (w >= b) {
        int ans = 0;
        while (n && h < a) h *= v[n], --n, ++ans;
        if (h >= a)
          return ans;
        else
          return -1;
      } else {
        queue<pair<long long, pair<long long, long long> > > q;
        q.push({h, {w, n}});
        long long ans = -1;
        while (!q.empty()) {
          pair<long long, pair<long long, long long> > x = q.front();
          q.pop();
          if (n - x.second.second >= 20) {
            if (mp[x]) continue;
            mp[x] = 1;
          }
          if (x.first >= a && x.second.first >= b) {
            if (ans == -1)
              ans = n - x.second.second;
            else
              ans = min(ans, n - x.second.second);
          } else if (x.first >= a) {
            while (x.second.second && x.second.first < b)
              x.second.first *= v[x.second.second], --x.second.second;
            if (x.second.first >= b) {
              if (ans == -1)
                ans = n - x.second.second;
              else
                ans = min(ans, n - x.second.second);
            }
          } else if (x.second.first >= b) {
            while (x.second.second && x.first < a)
              x.first *= v[x.second.second], --x.second.second;
            if (x.first >= a) {
              if (ans == -1)
                ans = n - x.second.second;
              else
                ans = min(ans, n - x.second.second);
            }
          } else {
            if (x.second.second == 0) continue;
            q.push({x.first * v[x.second.second],
                    {x.second.first, x.second.second - 1}});
            q.push(
                {x.first,
                 {x.second.first * v[x.second.second], x.second.second - 1}});
          }
        }
        return ans;
      }
    }
  }
}
long long a, b, h, w, n;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cin >> a >> b >> h >> w >> n;
  for (int i = 1; i <= n; ++i) cin >> v[i];
  sort(v + 1, v + n + 1);
  int a1 = getAns(a, b, h, w, n), a2 = getAns(b, a, h, w, n);
  if (a1 == -1)
    cout << a1;
  else if (a2 == -1)
    cout << a2;
  else
    cout << min(a1, a2);
  return 0;
}
