Question

Write a function to check if a number is a perfect cube?

Login to Submit

Examples

A number is a perfect cube if it can be written as the cube of an integer.

That means:
8 = 2³ for some integer x
(i.e., 2* 2* 2= 8)



input:3
output: false
 

input: 1 
output: true 
 

input: 8 
output: true