How would I go about giving the user the ability to add an unlimited number of key-value entries? Presumably something with a while loop.
Never mind. I figured it out. I didn't realize I could use the same variable over and over again.
Never mind. I figured it out. I didn't realize I could use the same variable over and over again.
latin_vocab = {} stop_word = "" while stop_word.lower() != "stop": new_key = input("\nLatin word: ") latin_vocab[new_key] = input("English meaning: ") print(" ") print("Current list: " + str(latin_vocab)) stop_word = input("\nStop? ")