+ 2
anytime I try running a program and I use user_input == "add" its always writing error ain't running is it wrng
2 Réponses
+ 2
user_input = "add"
+ 1
Everything's ok.
You just made a mistake.
To ASSIGN a VALUE to a VARIABLE, you must use a single equal sign.
BUT, you used two of them. We only use two of them to compare somthing to somthing else.
For exemple with the "if statements" to read the lines of codes below ONLY if an first value is equal to another.
exemple:
a=4
if a==4:
print("a is equal to 4")