Answer the question
In order to leave comments, you need to log in
How to fix TypeError: bad operand type for unary +: 'str'?
My code:
goal = str(input('Веди цель >> '))
goal_1 = str(input('Веди цель >> '))
goal_2 = str(input('Веди цель >> '))
goal_3 = str(input('Веди цель >> '))
if goal_3 =='all':
for i in range(3):
a = print( f'1. {goal}' )
b = print( f'2. {goal_1}' )
c = print( f'3. {goal_2}' )
what = str(input('И так какую цель ты виполнил 1, 2, 3 ? >> '))
if what == '1':
os.system('cls||clear')# clean cmd
a = + 'respect'
elif what == '2':
os.system('cls||clear')# clean cmd
b = + '*respect'
elif what == '3':
os.system('cls||clear')# clean cmd
c = + '*respect'
Answer the question
In order to leave comments, you need to log in
a = print(something) # a = None
a += text # None + text
cannot be added to None and str
# code must be inserted via code insertion
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question