Guest User

Untitled

a guest
Nov 8th, 2017
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.38 KB | None | 0 0
  1. print("Welcome to FaceSpace")
  2. user = input("Create a username:")
  3.  
  4. while True:
  5. passw = input("Create a password:")
  6. passv = input("confirm password:")
  7.  
  8. if passw != passv:
  9. print("passwords do not match")
  10.  
  11. if passw == passv:
  12. if passw == user:
  13. print("Username and Password cannot be the same try again.")
  14. else:
  15. break
  16.  
  17.  
  18.  
  19. def create_profile():
  20. name = input("What is your name?")
  21. birthday = input("Please enter your birthyear.")
  22. age = 2017 - int(birthday)
  23. email = input("What is your email address?")
  24. gender = input("Gender:")
  25. print("Verify Your Profile")
  26. print("Name: " + name)
  27. print("Age: " + str(age))
  28. print("Email:" + email)
  29. print("Gender: " + gender)
  30. use = print("Your username is " + user)
  31.  
  32.  
  33. create_profile()
  34.  
  35. input("Press any button to continue")
  36.  
  37. def login():
  38. tries = 0
  39. while tries < 5:
  40. username = input("Enter your username:")
  41. password = input("Enter your password:")
  42.  
  43. tries += 1
  44.  
  45. if username == user and password == passw:
  46. print("Login Sucessful. Welcome " + username + " !")
  47. break
  48.  
  49. if username == user and password != passw:
  50. print("Password is incorrect.")
  51.  
  52. if tries < 5:
  53. print("Try Again.")
  54.  
  55. if tries == 5:
  56. print("Account locked. Contact you Admin.")
  57. break
  58.  
  59. login()
Add Comment
Please, Sign In to add comment