import Foundation
let x: Int = readLine()!
let flag = false
for i in -200...200{
  for j in -200...200{
    if i**5-j**5==x{
      flag = true
      print(i,j)
      break
    }
  }
  if flag{
    break
  }
}
    
  