Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- while True:
- input1=input("What is your name? (enter 'STOP' to end the program)")
- file=open("text.txt","a")
- file.write(input1)
- if input1=="STOP":
- break
- file.close()
- input2=input("What is your nationality?")
- file=open("text.txt","a")
- file.write(" " + input2 + "\n")
- file.close()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement