fun main(args: Array<String>) = yorukatsu23c()

fun yorukatsu23c() {
    val (n, k) = readLine()!!.split(' ').map { it.toInt() }

    val answer = (1L..n).map {
        var curr = it
        var count = 0
        while (curr < k) {
            curr *= 2
            count++
        }
        1.0 / n * Math.pow(0.5, count.toDouble())
    }.sum()

    println(answer)
}
