x = input("do you have an account yes or no?") if x != ("yes"): quit() else: x = input("what is your username") y = input("what is your password") file=open("usernamepassword.txt","w+") file.write("Ben McNeill") file.write("bartisnoob") file.close() import random with open("usernamepassword.txt") as f: lines = f.readlines() print(random.choice(lines)) if x + y == ("usernamepassword.txt"): print("your password and username are correct") else: quit()It wont compare the file handling to what the input is, any help would be nice.
cant figure this out
Messages In This Thread |
cant figure this out - by louiecooper - Nov-29-2019, 11:56 AM
RE: cant figure this out - by ThomasL - Nov-29-2019, 12:12 PM
|
Users browsing this thread: 1 Guest(s)