Python字符串和整數(shù)連接我想在for循環(huán)中使用附加到它的整數(shù)創(chuàng)建字符串。像這樣:for i in range(1,11):
string="string"+i但它返回一個錯誤:TypeError: unsupported operand type(s) for +: 'int' and 'str'連接String和Integer的最佳方法是什么?
Python字符串和整數(shù)連接
慕的地6264312
2019-07-30 14:24:38