# while True runs forever until break stops the loop
while True:
    print("\n--- Common room ---")
    choice = input("(t)udy, (s)leep, (q)uit: ").strip().lower()

    if choice == "q":
        print("Goodnight!")
        break          # jump out of the loop
    elif choice == "t":
        print("You open your textbook...")
    elif choice == "s":
        print("You rest by the fire.")
    else:
        print("Pick t, s, or q.")
