from math import*
num1 = input("Enter the num ")
num2 = input("Enter the power ")
def exponent_func( num1 , num2):
return(pow ( str(num1) , str(num2) ))
exponent_func(num1 , num2)
from math import*
num1 = input("Enter the num ")
num2 = input("Enter the power ")
def exponent_func( num1 , num2):
return(pow ( int(num1) , int(num2) ))
exponent_func(num1 , num2)
使用
int
而不是str
相关问题 更多 >
编程相关推荐