import math



n = int(eval(input()))



for i in range(n):

    sqrt = int(math.sqrt(n-i))

    if(sqrt**2 == (n-i)):

        print((n-i))

        break
import math



n = int(eval(input()))



print((int(math.floor(n**0.5))**2))
import math

n = int(eval(input()))
for i in range(n):
    sqrt = int(math.sqrt(n - i))
    if sqrt**2 == (n - i):
        print((n - i))
        break

import math

n = int(eval(input()))
print((int(math.floor(n**0.5)) ** 2))

-for i in range(n): -    sqrt = int(math.sqrt(n - i)) -    if sqrt**2 == (n - i): -        print((n - i)) -        break +print((int(math.floor(n**0.5)) ** 2))