main = getLine >>= print . solve . (map read :: [String] -> [Int]) . words solve :: [Int] -> Double solve [k, n] = fromIntegral (sum [ x * n | x <- [0 .. k] ]) / (fromIntegral $ (k+1)*n)