class Array
  def csum
    res=Array.new(self.size+1,0)
    1.upto(self.size) do |i|
      res[i]=res[i-1]+self[i-1]
    end
    res
  end
end
N,H=gets.split.map(&:to_i)
as,bs=N.times.map{gets.split.map(&:to_i)}.transpose
as_max=as.max
bs.delete_if{|e|e<=as_max}
if bs.empty?
  puts H/as_max+1
  exit
end
bs.sort!
bs.reverse!
bs_csum=bs.csum
if H<=bs.inject(:+)
  idx=bs_csum.bsearch_index{|e|H<=e}
  idx=bs.size if idx.nil?
  ans=idx
else
  ans=bs.size+((H-bs.inject(:+))/as_max) +(((H-bs.inject(:+))%as_max)==0 ? 0 : 1)
end
puts ans
