t = int(input()) n_list = [int(input()) for i in range(t)] import math for n in n_list: print(math.floor(pow(n,0.5)))