Advertisement
Guest User

Untitled

a guest
Jul 20th, 2017
82
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.13 KB | None | 0 0
  1. data_bank = {"Jonathan" : "0213", "Ross": 'AsiansRS3xy'}
  2. end = False
  3. while (end == False):
  4.     print 'Please print your username and password'
  5.      
  6.     username = raw_input('Username:')
  7.     password = raw_input('Password:')
  8.      
  9.     if username in data_bank:
  10.         if password == data_bank[username]:
  11.             print 'ACCESS GRANTED'
  12.             end = True
  13.         else:
  14.             print 'ACCESS DENIED'
  15.  
  16.     elif username == "Grandmaster Champion" and password == "Iamgod":
  17.         print "Welcome Grandmaster Champion, please enter your new login information"
  18.         new_username = raw_input('New Username:')
  19.         new_password = raw_input('New Password:')
  20.         data_bank[new_username] = new_password
  21.         print "Your new information has been saved"
  22.  
  23.     elif username == "Destroyer of Worlds" and password == "Bomb":
  24.         print 'Welcome J. Robert Oppenheimer, select the username you would like to destroy'
  25.         old_username = raw_input("Username you would like to remove:")
  26.         if old_username in data_bank:
  27.             del data_bank[old_username]
  28.         else:
  29.             print 'User does not exist'
  30.         print 'User has been destroyed, LET NO EVIDENCE ESCAPE'
  31.  
  32.     else:
  33.         print 'User does not exist'
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement