Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def homeScreenArt():
- print("-*----------*------------*------*------*-")
- print("-----*-------------*--------------*------")
- print("-----&&&&&--&&--&&----&&----&&&&&--------")
- print("-*--&&---&&---&&--&&-*--&&---*--&----*---")
- print("-----&&&--&&----&&--&&----&&----&--------")
- print("-------&&&&&&-*----&&&&--*--&&--&&&&&----")
- print("----*-------&&--------*----------*-----*-")
- print("-------------&&--&--------*--------------")
- print("--*------------&-&--*--------*-------*---")
- print("----------*-----&-------Jack-Carter-2018-")
- print("-----*------------*--------------*-------n")
- def createLogin():
- criteriaMet=0
- print("n"*60,"-NEW USER-n")
- firstname=input("input your first name: ")
- age=input("input your age: ")
- #returns error message when a name with len < 3 is entered
- username=(firstname[0]+firstname[1]+firstname[2]+age)
- print("your username is",username)
- while criteriaMet<1:
- passEntered = input("input a password at least 7 characters long: ")
- if (len(passEntered))<7:
- print("password entered is",7-(len(passEntered))," characters to short")
- passEntered=input("input a password at least 7 characters long: ")
- print("password entered is",7-(len(passEntered))," characters to short")
- else:
- criteriaMet=+1
- criteriaMet2=0
- textFile=open(username, "w+")
- textFile.write("username:n")
- textFile.write(username)
- textFile.write("npassword:n")
- textFile.write(passEntered)
- print("user details have been saved to '",username,"'")
- while criteriaMet2<1:
- showCreds=input("Display user credentials? [y/n]")
- if showCreds=="y":
- criteriaMet2=+1
- print(textFile.read())
- textFile.close()
- print("if functional")
- elif showCreds=="n":
- criteriaMet2=+1
- #quizMenu()
- print("elif functional")
- else:
- print("Input invalid")
- print("else functional")
- def menu1():
- selection1=input("n1.Loginn2.New usernnnnnnn>>> ")
- if selection1=="1":
- login()
- elif selection1=="2":
- createLogin()
- else:
- print("ninvalid command")
- menu1()
- homeScreenArt()
- menu1()
Add Comment
Please, Sign In to add comment