import math

n,k = (int(x) for x in input().split())
p = 0
for i in range(1,n+1):
    a = max([math.ceil((math.log2(k/i))),0])
    p += 1/(n*(2**a))

print(p) import math math int(x) for x in input().split() for x in input().split() x input().split() ().split () input split for x in input().split() int(x) int x n,k = (int(x) for x in input().split()) n (int(x) for x in input().split()) k p = 0 p 0 for i in range(1,n+1):
    a = max([math.ceil((math.log2(k/i))),0])
    p += 1/(n*(2**a)) i range(1,n+1) range 1 n+1 n 1 a = max([math.ceil((math.log2(k/i))),0]) a max([math.ceil((math.log2(k/i))),0]) max [math.ceil((math.log2(k/i))),0] math.ceil((math.log2(k/i))) math.ceil math ceil math.log2(k/i) math.log2 math log2 k/i k i 0 p += 1/(n*(2**a)) p 1/(n*(2**a)) 1 n*(2**a) n 2**a 2 a print(p) print p p = 0 0 p a = max([math.ceil((math.log2(k/i))),0]) max([math.ceil((math.log2(k/i))),0]) a p += 1/(n*(2**a)) 1/(n*(2**a)) p k = (int(x) for x in input().split()) (int(x) for x in input().split()) k n,k = (int(x) for x in input().split()) (int(x) for x in input().split()) n
import math

n,k = (int(x) for x in input().split())
p = 0
for i in range(1,n+1):
    a = max([math.ceil((math.log2(k/i))),0])
    p += 1/(n*(2**a))

print(p)
