
main :: IO ()
main = do
    [a,b] <- (map read . words) <$> getLine
    putStr $ show $ getNum 0 a b

getNum :: Int -> Int -> Int -> Int
getNum n a b =
    if b - d <= 0 then (n + 1) else getNum (n + 1) a (b - d)
    where
        d = if n == 0 then a else (a - 1)
