The code I used:
command = input("Enter a command: ")
while command != "quit":
print("Your command was:", command)
command = input('Enter a command: ')
The interaction looked like this:
Enter a command: look
Your command was: look
Enter a command: forward
Your command was: forward
Enter a command: quit
while command != "quit":
print("Your command was:", command)
command = input('Enter a command: ')
The interaction looked like this:
Enter a command: look
Your command was: look
Enter a command: forward
Your command was: forward
Enter a command: quit
No comments:
Post a Comment