
r' :: IO [Int]
r'  =   unfoldr    (C.readInt . C.dropWhile (==' ')) <$> C.getLine


main :: IO ()
main = do
    [n,k] <- r'
    let res = sum $ map ((flip $ solve1 n) k) [1..n]
    print res


nDice :: Int -> Int -> Int
nDice n k = max 0 $ ceiling $ logBase 2 (fromIntegral k / fromIntegral n)

solve1 :: Fractional a => Int -> Int -> Int -> a
solve1 nn n k = (1 / fromIntegral nn)* ((1/2)^(nDice n k))


