Ask coding questions

← Back to all posts
Why is the if statement not printing the text
AayushK77

at the end of the code where the if statements are it doesnt .pack() the code on the screen like it should and idk why

Voters
AayushK77
Comments
hotnewtop
MrVoo

It looks like it works to me .-.

AayushK77

@MrVoo at the end where u enter the fight or run command does it print it on the screen cuz for me it doesnt

purchmat23

The reason why your run2/fight2 text label doesn't pop up is because the code to display the text is never actually ran. You can put it in a function that takes the users entry as a formal parameter and the entry_command1 function uses the "user_entry1" as the actual parameter like so.