Advertisement
Guest User

Untitled

a guest
Jan 7th, 2017
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.54 KB | None | 0 0
  1. dictionary = {}
  2.  
  3. with open("password.txt") as file:
  4. for line in file:
  5. e, p = line.strip().split(", ")
  6. dictionary[e] = p
  7.  
  8. email = input("Enter email: ")
  9. password = input("Enter new password: ")
  10.  
  11. dictionary[email] = password
  12.  
  13. with open("password.txt","w") as file:
  14. for e,p in dictionary.items():
  15. print(e,p,sep=", ",file=file)
  16.  
  17. you@example.com, old_password
  18. noone@example.com, uzt(647zt2(/r
  19. lastone@email.com, zzzzzappp!
  20. youtoo@example.com, password
  21. xkcd@example.com, ok horse battery staple
  22. weall@example.com, topsecret
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement