N=int(input()) P=float(input()) if N>=200: Ans=1 else: Ans=1-pow(1-P,N) print(Ans)