title: String to dictionary conversion
body: <p>My code involves importing and exporting usernames and passwords in the form of a dictionary. In order to export the dictionary i changed it in to a string.
  This is the imported text file (it is in the same format that the code exports in):</p>
  
  <pre><code>{'account1': 'password'}{'account2': 'password'}
  </code></pre>
  
  <p>the code to export is as follows:</p>
  
  <pre><code>accounts=open("accounts.txt","r")
  accounts=accounts.read()
  
  newaccount={username:password}#user name and password are user defined 
  str1=str(newaccount)
  updated=open("accounts.txt","w")
  updated.write(accounts)
  updated.write(str1)
  updated.close()
  </code></pre>
  
  <p>I want the dictionary to look like this:</p>
  
  <pre><code>{'account1':'password', 'account2':'password'}
  </code></pre>