【发布时间】:2018-03-31 20:38:16
【问题描述】:
我目前在 python3 中的程序遇到问题。
我最近遇到了错误: 类型错误:+ 的不支持的操作数类型:'int' 和 'str'
我不知道问题可能是什么,因此非常感谢任何帮助。
lengths = input("Enter the Lengths of the Sides of the Shape Seperated by commas: ").split(',')
answer = sum(lengths)
print("+".join(lengths) + "= %s" % (answer))
【问题讨论】:
标签: python python-3.x