#include <stdio.h>
#include <math.h>
#include <limits.h>
unsigned long long f(long long i, long long j){
    return (unsigned long long)(pow(i, 5) - pow(j, 5));
}
int main(){
    unsigned long long X;
    scanf("%llu", &X);
    for( long long i = 0; i <= 500; i++ ){
        for( long long j = 0; j <= 500 ; j++ ){
            if( f(i, j) == X ){
                printf("%lld %lld\n", i, j);
                goto OUT;
            }else if( f(-i, -j) == X ){
                printf("%lld %lld\n", -i, -j);
                goto OUT;
            }else if( f(i, -j) == X ){
                printf("%lld %lld\n", i, -j);
                goto OUT;
            }else if( f(-i, j) == X ){
                printf("%lld %lld\n", -i, j);
                goto OUT;
            }
        }
    }
OUT:
    return 0;
}