指数大于1,如求x的n次方
x
n
pow(x, n)
指数小于1,这里要求底数必须大于0,即x > 0,如求x的平方根:
x > 0
import math math.sqrt(x)
或者:
pow(x, 1/2)