import math
answer = 0
n,k = map(int,input().split())
for i in range(1,n+1):
  if(i>=k):
    answer +=1/n
  else:
    answer += 1/(2**math.ceil(math.log2(k/i)))/n
print(answer) import math math answer = 0 answer 0 n,k = map(int,input().split()) n map(int,input().split()) map int input().split() ().split () input split k for i in range(1,n+1):
  if(i>=k):
    answer +=1/n
  else:
    answer += 1/(2**math.ceil(math.log2(k/i)))/n i range(1,n+1) range 1 n+1 n 1 if(i>=k):
    answer +=1/n
  else:
    answer += 1/(2**math.ceil(math.log2(k/i)))/n i>=k i k answer +=1/n answer 1/n 1 n answer += 1/(2**math.ceil(math.log2(k/i)))/n answer 1/(2**math.ceil(math.log2(k/i)))/n 1/(2**math.ceil(math.log2(k/i))) 1 2**math.ceil(math.log2(k/i)) 2 math.ceil(math.log2(k/i)) math.ceil math ceil math.log2(k/i) math.log2 math log2 k/i k i n print(answer) print answer k = map(int,input().split()) map(int,input().split()) k answer += 1/(2**math.ceil(math.log2(k/i)))/n 1/(2**math.ceil(math.log2(k/i)))/n answer answer = 0 0 answer n,k = map(int,input().split()) map(int,input().split()) n answer +=1/n 1/n answer
import math
answer = 0
n,k = map(int,input().split())
for i in range(1,n+1):
  if(i>=k):
    answer +=1/n
  else:
    answer += 1/(2**math.ceil(math.log2(k/i)))/n
print(answer)