a = 10
b = "5"
result = a + b
print(result)TypeError: unsupported operand type(s) for +: 'int' and 'str'
a = 10
b = "5"
result = a + int(b)
print(result)I mixed types without noticing and tried to add them directly.
| Name | Name | Last commit date | ||
|---|---|---|---|---|
parent directory.. | ||||
a = 10
b = "5"
result = a + b
print(result)TypeError: unsupported operand type(s) for +: 'int' and 'str'
a = 10
b = "5"
result = a + int(b)
print(result)I mixed types without noticing and tried to add them directly.