eval() 传入的参数是个字符串类型,函数功能是去掉参数外面的引号,并且执行余下语句的函数(先运算后去掉引号)
print(eval('1+2')) a=input('输入') b=input('输入') print(eval(a+b),type(eval(a+b)))