[Solved] TypeError: unsupported operand type(s) for +: ‘type’ and ‘str’ [closed]


I don’t know exactly what you were going for, but this should fix most of it:

print('You have ' + turns + ' more guesses')

no need to use str for stuff like this and don’t use + outside the parenthesis of print()

This assumes your turns variable is a string, but if it is a number it should be:

print('You have ' + str(turns) + ' more guesses')

0

solved TypeError: unsupported operand type(s) for +: ‘type’ and ‘str’ [closed]