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

a = []
b = []
num_attack = 0

for _ in range(N):
	a_i, b_i = map(int, input().split())
	a.append(a_i)
	b.append(b_i)

Strong_b = [b_i for b_i in b if b_i > max(a)]

while sum(Strong_b) < H :
	H -= max(a)
	num_attack += 1

while H > 0 :
	H -= max(Strong_b)
	max_index = Strong_b.index(max(Strong_b))
	Strong_b[max_index] = 0
	num_attack += 1			 

print(num_attack)
