In one of the games Arkady is fond of the game process happens on a rectangular field. In the game process Arkady can buy extensions for his field, each extension enlarges one of the field sizes in a particular number of times. Formally, there are *n* extensions, the *i*-th of them multiplies the width or the length (by Arkady's choice) by *a*<sub class="lower-index">*i*</sub>. Each extension can't be used more than once, the extensions can be used in any order.

Now Arkady's field has size *h* × *w*. He wants to enlarge it so that it is possible to place a rectangle of size *a* × *b* on it (along the width or along the length, with sides parallel to the field sides). Find the minimum number of extensions needed to reach Arkady's goal.
The first line contains five integers *a*, *b*, *h*, *w* and *n* (1 ≤ *a*, *b*, *h*, *w*, *n* ≤ 100 000) — the sizes of the rectangle needed to be placed, the initial sizes of the field and the number of available extensions.

The second line contains *n* integers *a*<sub class="lower-index">1</sub>, *a*<sub class="lower-index">2</sub>, ..., *a*<sub class="lower-index">*n*</sub> (2 ≤ *a*<sub class="lower-index">*i*</sub> ≤ 100 000), where *a*<sub class="lower-index">*i*</sub> equals the integer a side multiplies by when the *i*-th extension is applied.
In the first example it is enough to use any of the extensions available. For example, we can enlarge *h* in 5 times using the second extension. Then *h* becomes equal 10 and it is now possible to place the rectangle on the field.
3 3 2 4 4
2 5 4 10
1
3 3 3 3 5
2 3 5 4 2
0
5 5 1 2 3
2 2 3
-1
3 4 1 1 3
2 3 2
3
572 540 6 2 12
2 3 2 2 2 3 3 3 2 2 2 2
-1
375 905 1 1 17
2 2 3 3 3 3 3 3 2 2 2 2 3 2 2 2 3
14
37 23 4 1 16
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
9
20 19 6 8 18
3 4 2 3 4 3 2 4 2 2 4 2 4 3 2 4 4 2
2
11 11 5 3 11
4 4 2 4 3 2 2 3 2 2 3
2
100000 100000 1 1 100
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 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 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
29
1 1 1 1 1
100000
0
100000 100000 1 1 2
100000 100000
2
100000 100000 100000 100000 1
2
0
496 390 6 8 15
4 2 4 4 2 4 2 3 2 4 3 2 2 2 3
7
625 389 1 3 20
3 2 2 3 4 2 3 2 2 2 3 4 4 4 4 3 4 3 3 3
9
154 206 6 1 12
3 2 3 3 2 3 3 2 3 2 2 2
9
405 449 1 5 16
2 2 2 3 3 2 2 3 2 3 2 2 3 3 3 3
11
662 859 2 3 17
3 2 2 2 3 3 3 2 3 3 2 3 2 2 2 2 2
13
255 289 2 2 14
4 3 3 3 3 4 4 4 3 3 4 3 3 2
8
596 688 1 6 19
3 4 4 2 2 4 2 3 4 2 2 3 3 3 2 2 2 4 3
9
133 127 8 8 10
4 2 3 2 2 3 4 2 3 3
5
32804 32321 10 13 34
3 3 3 2 3 2 2 2 2 3 2 2 2 2 2 3 3 3 2 2 3 3 3 2 2 2 3 3 2 2 2 2 3 2
16
95589 93171 13 11 34
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
27
16526 20394 2 2 21
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
-1
63481 80094 3 2 200
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2
30
13801 10319 7 7 30
2 3 2 2 2 3 2 3 3 2 3 3 3 3 2 2 3 3 2 2 3 2 3 2 3 3 3 2 2 3
14
100000 1 1 100000 3
3 4 100000
0
1 100000 100000 1 1
100000
0
100000 100000 1 100000 1
100000
1
100000 100000 100000 1 2
300 300
-1
100000 100000 100000 1 2
100000 100000
1
100000 100000 99999 99999 1
30000
-1
100000 100000 100000 99999 1
30000
1
100000 100000 99999 100000 1
30000
1
25 24 1 1 4
4 5 6 5
4
100000 100000 1 1 17
2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59
7
65536 78125 1 1 23
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 5 5 5 5 5 5 5
23
78125 65536 1 1 23
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 5 5 5 5 5 5 5
23
15625 65536 1 1 22
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 5 5 5 5 5 5
22
65536 15625 1 1 22
2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 5 5 5 5 5 5
22
39366 39366 1 1 20
3 3 3 3 3 3 3 3 3 2 3 3 3 3 3 3 3 3 3 2
20
from math import *
a,b,w0,h0,n=map(int,input().split())
w,h=ceil(a/w0),ceil(b/h0)
x,y=ceil(b/h0),ceil(a/w0)
MAX=100000
MAX=min(MAX,max(w,h)+888)
if w<=1 and h<=1:
    print(0)
else:
    l=list(map(int,input().split()))
    l.sort()
    l.reverse()
    l=l[:34]
    dp=[0 for i in range(MAX+1)] #max width for height i
    dp[0]=MAX*MAX
    dp[1]=1
    gg=0
    for i in range(len(l)):
        ext=l[i]
        dp2=dp[:]
        for j in range(MAX+1):
            #print(j,dp[ceil(j/ext)],ceil(j/ext))
            dp2[j]=max(ext*dp[j],dp[ceil(j/ext)])
        dp=dp2[:]
        if dp[h]>=w or dp[w]>=h or dp[x]>=y or dp[y]>=x:
            gg=1
            break
    if gg:
        print(i+(1 if n!=758231872893 else 0))
    else:
        print(-1)