t = int(input()) for i in range(t): n = int(input()) l,r = 1,10**18 while l < r: c = (l+r+1)//2 if c**2 > n: r = c-1 else: l = c print(l)