Cube Roots

Irmen de Jong irmen at NOSPAM-REMOVETHIS-xs4all.nl
Thu Jan 2 14:50:15 EST 2003


John Smith wrote:
> How does one take a root higher than square roots in Python?  Can I take the
> cube root of a number?

N-root of X: raise X to the power 1/N:

 >>> 16**(1/4.0)
2.0

Irmen





More information about the Python-list mailing list