import sys

(N, H) = tuple(map(int, input().split(" ")))

a = []
b = []
result = -1

for i in range(N):
    (ai,bi) = tuple(map(int, input().split(" ")))
    a.append(ai)
    b.append(bi)

a_max = max(a)
sorted(b).reverse()
b_length = len(b)

for i, bi in enumerate(b):
    if bi < a_max:
        b_length = i

S = 0

for l in range(b_length):
    S += b[l]
    if S >= H:
        result = l + 1
        print(result)
        sys.exit()

j = b_length

result = b_length + int((H - S)/a_max)

print(result)
