import sys from scipy.optimize import newton import numpy as np read = sys.stdin.buffer.read readline = sys.stdin.buffer.readline readlines = sys.stdin.buffer.readlines P, Q = map(int, read().split()) def f(x): return x * x - Q * x * np.log2(x) - P x = newton(f, x0=10**20, maxiter=1000) print(x)