jeudi 22 février 2018

Making an incomplete IF statement

I am making a small dungeon crawler text game and there is a certain code I want to use, but i can't figure out how. I want to create an IF statement that has an incomplete end statement.

if cmd.lower() == "examine ...":

the three dots will be anything the user chooses. The number of options are too great to have that many IF statements for every single one. Is there anyways that I can just take the "Examine" part of their input and use that in an IF statement?

Aucun commentaire:

Enregistrer un commentaire