Twilight Sparkle was playing Ludo with her friends Rainbow Dash, Apple Jack and Flutter Shy. But she kept losing. Having returned to the castle, Twilight Sparkle became interested in the dice that were used in the game.

The dice has m faces: the first face of the dice contains a dot, the second one contains two dots, and so on, the m-th face contains m dots. Twilight Sparkle is sure that when the dice is tossed, each face appears with probability $\frac{1}{m}$. Also she knows that each toss is independent from others. Help her to calculate the expected maximum number of dots she could get after tossing the dice n times.


-----Input-----

A single line contains two integers m and n (1 ≤ m, n ≤ 10^5).


-----Output-----

Output a single real number corresponding to the expected maximum. The answer will be considered correct if its relative or absolute error doesn't exceed 10 ^{ - 4}.


-----Examples-----
Input
6 1

Output
3.500000000000

Input
6 3

Output
4.958333333333

Input
2 2

Output
1.750000000000



-----Note-----

Consider the third test example. If you've made two tosses:  You can get 1 in the first toss, and 2 in the second. Maximum equals to 2.  You can get 1 in the first toss, and 1 in the second. Maximum equals to 1.  You can get 2 in the first toss, and 1 in the second. Maximum equals to 2.  You can get 2 in the first toss, and 2 in the second. Maximum equals to 2. 

The probability of each outcome is 0.25, that is expectation equals to: $(2 + 1 + 2 + 2) \cdot 0.25 = \frac{7}{4}$

You can read about expectation using the following link: http://en.wikipedia.org/wiki/Expected_value

Difficulty: competition

Starter code:

Solutions:
"""
Codeforces Contest 259 Div 1 Problem A

Author  : chaotic_iak
Language: Python 3.3.4
"""

def main():
    m,n = read()
    print(m - sum((i/m)**n for i in range(1,m)))

################################### NON-SOLUTION STUFF BELOW

def read(mode=2):
    # 0: String
    # 1: List of strings
    # 2: List of integers
    inputs = input().strip()
    if mode == 0: return inputs
    if mode == 1: return inputs.split()
    if mode == 2: return map(int, inputs.split())

def read_str(): return read(0)
def read_int(): return read(2)[0]

def write(s="\n"):
    if isinstance(s, list): s = " ".join(map(str, s))
    s = str(s)
    print(s, end="")

main()

__author__ = 'Jacob Dlougach'

def __starting_point():
    m, n = map(int, input().split())
    result = 0
    for i in range(m):
        result += ((i + 1) / m) ** n
    print('{:.9}'.format(m + 1 - result))
__starting_point()

m,n = [int(x) for x in input().split()]

ans = m
for i in range(1, m):
    ans -= (i/m)**n

print("%0.10f"%ans)


m,n=list(map(int,input().split()))

P=1
ans=0

while(m>0):
    p=P*(1-(((m-1)/m)**n))
    ans+=m*p
    m-=1
    P-=p
print(ans)


m, n = list(map(int, input().split()))
pvar = 0
ans = 0
for i in range(1, m + 1):
    var = (i / m) ** n
    ans += i * (var - pvar)
    pvar = var
print(ans)


m, n = list(map(int, input().split()))
f = lambda x: (x / m) ** n
print("{:.9}".format(sum((f(i + 1) - f(i)) * (i + 1) for i in range(m))))


m, n = list(map(int, input().split()))
print("{:.9}".format(m - sum((i / m) ** n for i in range(m))))


m, n=list(map(int, input().split(' ')))
sumx=0
for i in range(1, m+1):
    sumx+=i*((i/m)**n-((i-1)/m)**n)
print(sumx)


import math
m,n=map(int,input().split(' '))

a = 0
b = 0
o = 0
for i in range(m) :
    a = ( (i+1)/m ) ** n;
    o = o + (a - b) * (i+1)
    b = a
print(o)

m, n = tuple(map(int, input().split()))

ans = 0
for x in range(1, m + 1):
    ans += x * ((x / m)**n - ((x - 1)/m)**n)
print('%0.9f' % ans)

m, n = list(map(int, input().split()))
t = [pow(1 - i / m, n) for i in range(m + 1)]
print(sum((t[i] - t[i + 1]) * (m - i) for i in range(m)))


from math import pow

m , n = list(map(int,input().split()))
ans = 0.0
sumx = 1.0

for i in range(1,m+1):
    ans += i * (pow(i/m,n)-pow((i-1.0)/m,n))
print('%.15f'%ans)


from math import pow
m , n = list(map(int,input().split()))
ans = 0.0
for i in range(1,m+1):
    ans += i * (pow(i/m,n)-pow((i-1.0)/m,n))
print('%.15f'%ans)


m, n = map(int, input().split());

sum = 0.0;

for i in range(1, m + 1):
	sum += i * ((1.0 * i / m) ** n - ((i - 1.0) / m) ** n);

print ("%.10lf" % sum);

m, n = map(int, input().split())
t = [pow(1 - i / m, n) for i in range(m + 1)]
print(sum((t[i] - t[i + 1]) * (m - i) for i in range(m)))

m, n = [int(x) for x in input().split()]
print(sum(x * (pow(x / m, n) - pow((x - 1) / m, n)) for x in range(1, m + 1)))


def main():
    m, n = map(int, input().split())
    print(sum((i + 1) * (((i + 1) / m) ** n - (i / m) ** n) for i in range(m)))


def __starting_point():
    main()
__starting_point()

def main():
    m, n = map(int, input().split())
    print(m - sum((i / m) ** n for i in range(m)))


def __starting_point():
    main()
__starting_point()

m, n = [int(i) for i in input().split()]
ans = 0
for i in range(1,m+1):
    tmp_a = pow(i/m,n)
    tmp_b = pow((i-1)/m,n)
    ans += i*(tmp_a-tmp_b)
print(ans)


import math


def solve():
    [m, n] = [int(x) for x in input().split()]

    ans = 0
    for i in range(m):
        ans += pow(i / m, n)

    ans = m - ans
    print(ans)

def __starting_point():
    solve()





__starting_point()

m, n = [int(x) for x in input().split()]


print(sum([i *((i/m) ** n - ((i-1)/m) ** n) for i in range(1, m + 1)]))

from math import *
def bpow(a, n):
    res = 1
    while n > 0:
        if n % 2 != 0:
            res *= a
        a *= a
        n >>= 1
    return res
M, N = map(int, input().split())
sm = 0
for i in range(1, M):
    sm += bpow(i / M, N)
print(M - sm)

m, n = list(map(int, input().split()))

ret = m
for i in range(m):
    ret -= pow(i / m, n)

print(ret)


m,n=[int(i) for i in input().split()]
r=m
for i in range(1,m):
	r-=(i/m)**n
print(r)

import sys, math, string, fractions, functools, collections
sys.setrecursionlimit(10**7)
RI=lambda x=' ': list(map(int,input().rstrip().split(x)))
RS=lambda x=' ': input().rstrip().split(x)
dX= [-1, 1, 0, 0,-1, 1,-1, 1]
dY= [ 0, 0,-1, 1, 1,-1,-1, 1]
mod=int(1e9+7)
eps=1e-6
MAX=1010
#################################################
ans=0
m, n = RI()
for i in range(1, m+1):
    ans+= i * (pow(i/m,n) - pow((i-1)/m, n))
print("%.12f" % ans)