title: Saving multiple usernames and passwords in an external file for python
body: <p><strong>My Current code is a simple 1 username and 1 password consistency.
  I wish to find the most simple and effective way to store several different passwords in e separate file form the python program and allow them to be used and if correct, allow the user to access the rest of the code.
  The code is as follows currently it does work but i'm trying to find a more intricate way as i said above:</strong></p>
  
  <pre><code>loggedin = False
  while loggedin == False:
      username = input("Username:")
      password = input("Password:")
      if password == "Player1" and username == "Player1":
          print ("Logged in as Player1")
          loggedin = True
  
      else:
          print ("Incorrect Password. Please try again.")
  </code></pre>