def main():

    N, H = map(int, input().split())
    sword = []
    for _ in range(N):
        a, b = map(int, input().split())
        sword.append([a, b])
    sword.sort(key = lambda x: x[1], reverse= True)

    count = float('inf')

    # the case with just throwing the swords
    damage = 0
    count1 = 0
    for a, b in sword:
        damage += b
        count1 += 1
        if damage >= H:
            break
    if damage >= H:
        count = min(count, count1)

    sword.sort(key = lambda x: x[0], reverse = True)
    a0, b0 = sword.pop(0)
    sword.sort(key = lambda x: x[1], reverse = True)

    damage = 0
    count2 = 0
    i = 0
    while i < len(sword) and sword[i][1] > a0:
        damage += sword[i][1]
        count2 += 1
        i += 1
    if damage < H:
        c = (H - damage - b0) // a0
        if (H - damage - b0) % a0 != 0:
            c += 1
        count2 += c + 1
        count = min(count, count2)

    return count