x = int(eval(input()))

for i in range(-118, 120):

    for j in range(-119, 119):

        if i**5 - j**5 == x:

            print(('{} {}'.format(i,j)))

            break

    else:

        continue

    break
def make_divisors(n):

    divisors = []

    for i in range(1, int(n**0.5)+1):

        if n % i == 0:

            divisors.append(i)

            if i != n // i:

                divisors.append(n//i)



    divisors.sort()

    return divisors

x = int(eval(input()))

L = make_divisors(x)

for i in L:

    for a in range(-118,120):

        if a**5 - (a-i)**5 == x:

            print(('{} {}'.format(a,a-i)))

            break

    else:

        continue

    break
x = int(eval(input()))
for i in range(-118, 120):
    for j in range(-119, 119):
        if i**5 - j**5 == x:
            print(("{} {}".format(i, j)))
            break
    else:
        continue
    break

def make_divisors(n):
    divisors = []
    for i in range(1, int(n**0.5) + 1):
        if n % i == 0:
            divisors.append(i)
            if i != n // i:
                divisors.append(n // i)
    divisors.sort()
    return divisors


x = int(eval(input()))
L = make_divisors(x)
for i in L:
    for a in range(-118, 120):
        if a**5 - (a - i) ** 5 == x:
            print(("{} {}".format(a, a - i)))
            break
    else:
        continue
    break

+def make_divisors(n): +    divisors = [] +    for i in range(1, int(n**0.5) + 1): +        if n % i == 0: +            divisors.append(i) +            if i != n // i: +                divisors.append(n // i) +    divisors.sort() +    return divisors + + -for i in range(-118, 120): -    for j in range(-119, 119): -        if i**5 - j**5 == x: -            print(("{} {}".format(i, j))) +L = make_divisors(x) +for i in L: +    for a in range(-118, 120): +        if a**5 - (a - i) ** 5 == x: +            print(("{} {}".format(a, a - i)))