import math
N, K = map(int, input().split())
ans = 0
for i in range(1, N + 1):
    num_success = max(0,math.ceil(math.log2(K / i)))
    ans += (1 / 2) ** num_success
   
print(ans / N)
         import math math N, K = map(int, input().split()) N map(int, input().split()) map int input().split() ().split () input split K ans = 0 ans 0 for i in range(1, N + 1):
    num_success = max(0,math.ceil(math.log2(K / i)))
    ans += (1 / 2) ** num_success
    i range(1, N + 1) range 1 N + 1 N 1 num_success = max(0,math.ceil(math.log2(K / i))) num_success max(0,math.ceil(math.log2(K / i))) max 0 math.ceil(math.log2(K / i)) math.ceil math ceil math.log2(K / i) math.log2 math log2 K / i K i ans += (1 / 2) ** num_success ans (1 / 2) ** num_success 1 / 2 1 2 num_success print(ans / N) print ans / N ans N K = map(int, input().split()) map(int, input().split()) K ans = 0 0 ans num_success = max(0,math.ceil(math.log2(K / i))) max(0,math.ceil(math.log2(K / i))) num_success ans += (1 / 2) ** num_success (1 / 2) ** num_success ans N, K = map(int, input().split()) map(int, input().split()) N
import math
N, K = map(int, input().split())
ans = 0
for i in range(1, N + 1):
    num_success = max(0,math.ceil(math.log2(K / i)))
    ans += (1 / 2) ** num_success
   
print(ans / N)
        
