from math import *
n, k = map(int, input().split())
r = 0
for i in range(1, n + 1):
    if (i >= k):
        r += n + 1 - i
        break
    r += 1 / 2**ceil(log(k / i, 2))
print(r / n) from math import * n, k = map(int, input().split()) n map(int, input().split()) map int input().split() ().split () input split k r = 0 r 0 for i in range(1, n + 1):
    if (i >= k):
        r += n + 1 - i
        break
    r += 1 / 2**ceil(log(k / i, 2)) i range(1, n + 1) range 1 n + 1 n 1 if (i >= k):
        r += n + 1 - i
        break
     i >= k i k r += n + 1 - i r n + 1 - i n + 1 n 1 i break r += 1 / 2**ceil(log(k / i, 2)) r 1 / 2**ceil(log(k / i, 2)) 1 2**ceil(log(k / i, 2)) 2 ceil(log(k / i, 2)) ceil log(k / i, 2) log k / i k i 2 print(r / n) print r / n r n r += 1 / 2**ceil(log(k / i, 2)) 1 / 2**ceil(log(k / i, 2)) r n, k = map(int, input().split()) map(int, input().split()) n k = map(int, input().split()) map(int, input().split()) k r += n + 1 - i n + 1 - i r r = 0 0 r
from math import *
n, k = map(int, input().split())
r = 0
for i in range(1, n + 1):
    if (i >= k):
        r += n + 1 - i
        break
    r += 1 / 2**ceil(log(k / i, 2))
print(r / n)
