#include<stdio.h>
long long int f(long long int a)
{
	return a * a * a * a * a;
}
int main()
{
	long long int x;
	scanf("%lld", &x);
	long long int a, d;
	for (d = 1; d * d <= x; d++)
	{
		if (x % d == 0)
		{
			a = 0;
			while (f(a + d) - f(a) < x)
				a++;
			if (f(a + d) - f(a) == x)
			{
				printf("%lld %lld\n", a + d, a);
				return 0;
			}
			d = x / d;
			a = 0;
			while (f(a + d) - f(a) < x)
				a++;
			if (f(a + d) - f(a) == x)
			{
				printf("%lld %lld\n", a + d, a);
				return 0;
			}
			d = x / d;
		}
	}
	x *= -1;
	for (d = 1; d * d <= -1 * x; d++)
	{
		if (x % d == 0)
		{
			a = 0;
			while (f(a - d) - f(a) < x)
				a++;
			if (f(a - d) - f(a) == x)
			{
				printf("%lld %lld\n", -a + d, -a);
				return 0;
			}
			d = x / d;
			a = 0;
			while (f(a - d) - f(a) < x)
				a++;
			if (f(a - d) - f(a) == x)
			{
				printf("%lld %lld\n", -a + d, -a);
				return 0;
			}
			d = x / d;
		}
	}
	return 0;
}