当前位置:网站首页>Program error record 1:valueerror: invalid literal for int() with base 10: '2.3‘

Program error record 1:valueerror: invalid literal for int() with base 10: '2.3‘

2022-07-05 08:36:00 A little brother who studies mathematical modeling

The above error is caused by :

int() In parentheses, you can only turn things that are integers

# a=input()
# a1,a2,a3=a.split()
a1,a2,a3=1,2.3,4.7
print(float(a1)+float(a2)+float(a3))

Rumor has it

 Content =int(float( Content ))

原网站

版权声明
本文为[A little brother who studies mathematical modeling]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/02/202202140542585641.html