#!/usr/bin/env python
import sys 
input = sys.stdin.readline

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

for i in range(1, n+1):
    score = i 
    tmpans = 1/n 
    while score < k:
        score *= 2
        tmpans *= 1/2 
    ans += tmpans

print(ans) import sys sys input = sys.stdin.readline input sys.stdin.readline sys.stdin sys stdin readline 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):
    score = i 
    tmpans = 1/n 
    while score < k:
        score *= 2
        tmpans *= 1/2 
    ans += tmpans i range(1, n+1) range 1 n+1 n 1 score = i score i tmpans = 1/n tmpans 1/n 1 n while score < k:
        score *= 2
        tmpans *= 1/2 
     score < k score k score *= 2 score 2 tmpans *= 1/2 tmpans 1/2 1 2 ans += tmpans ans tmpans print(ans) print ans tmpans = 1/n 1/n tmpans ans = 0 0 ans score *= 2 2 score score = i i score k = map(int, input().split()) map(int, input().split()) k ans += tmpans tmpans ans n, k = map(int, input().split()) map(int, input().split()) n tmpans *= 1/2 1/2 tmpans input = sys.stdin.readline sys.stdin.readline input
#!/usr/bin/env python
import sys 
input = sys.stdin.readline

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

for i in range(1, n+1):
    score = i 
    tmpans = 1/n 
    while score < k:
        score *= 2
        tmpans *= 1/2 
    ans += tmpans

print(ans)
