findThirdRoot :: Integral a => a -> Double
findThirdRoot q = findThirdRoot' q'' $ q'' / 2
    where
        q'' = fromIntegral q
        findThirdRoot' q' xn
            | abs (xn * xn * xn - q') < 0.00001 * q' = xn
            | otherwise                              = findThirdRoot' q' xn2
            where xn2 = xn - (xn * xn * xn - q') / (3 * xn * xn)

main :: IO ()
main = putStr . unlines . map show . map findThirdRoot .
    takeWhile (/= -1) . map read . lines =<< getContents