import math

n, k = map(int, input().split())

# for small
score = 0
times = []
for i in range(1, min(n + 1, k)):
    times.append(math.ceil(math.log2((k / i))))

if len(times):
    bottom_max = times[0]
    for t in times:
        score += 2 ** (bottom_max - t)
    score /= 2 ** (bottom_max) * n

# for big
big = [i for i in range(k, max(k, n + 1))]
score += len(big) / n
print('{:.10f}'.format(score)) import math math n, k = map(int, input().split()) n map(int, input().split()) map int input().split() ().split () input split k score = 0 score 0 times = [] times [] for i in range(1, min(n + 1, k)):
    times.append(math.ceil(math.log2((k / i)))) i range(1, min(n + 1, k)) range 1 min(n + 1, k) min n + 1 n 1 k times.append(math.ceil(math.log2((k / i)))) times.append times append math.ceil(math.log2((k / i))) math.ceil math ceil math.log2((k / i)) math.log2 math log2 k / i k i if len(times):
    bottom_max = times[0]
    for t in times:
        score += 2 ** (bottom_max - t)
    score /= 2 ** (bottom_max) * n

# for big len(times) len times bottom_max = times[0] bottom_max times[0] times 0 for t in times:
        score += 2 ** (bottom_max - t)
     t times score += 2 ** (bottom_max - t) score 2 ** (bottom_max - t) 2 bottom_max - t bottom_max t score /= 2 ** (bottom_max) * n score 2 ** (bottom_max) * n 2 ** (bottom_max) 2 bottom_max n i for i in range(k, max(k, n + 1)) for i in range(k, max(k, n + 1)) i range(k, max(k, n + 1)) range k max(k, n + 1) max k n + 1 n 1 for i in range(k, max(k, n + 1)) i big = [i for i in range(k, max(k, n + 1))] big [i for i in range(k, max(k, n + 1))] score += len(big) / n score len(big) / n len(big) len big n print('{:.10f}'.format(score)) print '{:.10f}'.format(score) '{:.10f}'.format '{:.10f}' format score times = [] [] times score += 2 ** (bottom_max - t) 2 ** (bottom_max - t) score bottom_max = times[0] times[0] bottom_max score += len(big) / n len(big) / n score k = map(int, input().split()) map(int, input().split()) k n, k = map(int, input().split()) map(int, input().split()) n score = 0 0 score score /= 2 ** (bottom_max) * n 2 ** (bottom_max) * n score big = [i for i in range(k, max(k, n + 1))] [i for i in range(k, max(k, n + 1))] big
import math

n, k = map(int, input().split())

# for small
score = 0
times = []
for i in range(1, min(n + 1, k)):
    times.append(math.ceil(math.log2((k / i))))

if len(times):
    bottom_max = times[0]
    for t in times:
        score += 2 ** (bottom_max - t)
    score /= 2 ** (bottom_max) * n

# for big
big = [i for i in range(k, max(k, n + 1))]
score += len(big) / n
print('{:.10f}'.format(score))
