import math
import bisect
n, h = map(int, input().split())
h2 = h
x = []
y = []
for i in range(n):
	a = list(map(int, input().split()))
	x.append(a[0])
	y.append(a[1])
c = sum(y)
d = max(x)
y.sort()
e = bisect.bisect_left(y,d)
f = sum(y[e:])
g = sorted(y[e:], reverse= True)
y.sort(reverse=True)
cnt = 0
cnt2 = 0
if h <= f:
	for i in g:
		h -= i
		cnt += 1
		if h <= 0:
			print (cnt)
			exit()
elif h <= c:
	for i in y:
		h -= i
		cnt += 1
		if h <= 0:
			print (cnt)
			exit()
else:
	cnt += math.ceil((h-c)/d)
	#print (cnt)
	cnt2 += math.ceil((h-f)/d)
	#print (cnt2)
	h -= cnt * d
	h2 -= cnt2 * d
	for i in y:
		h -= i
		cnt += 1
		if h <= 0:
			break
	for i in g:
		h2 -= i
		cnt2 += 1
		if h2 <= 0:
			break
print (min(cnt,cnt2))