def f{var Array(a,b)=readLine split" "map{_.toInt};println(a+b*b/a+2>>2);f};f