def lscan; gets.split.map(&:to_i); end a,b = lscan p (0..1e99).bsearch{|t| t*b*Math::log2(t)+a < t*t}