title: How to solve 'Private Test Cases' PySchool
body: <p>Im really get confused.
  Im solving PySchool Practices for university and get a problem at Topic 13: Question 2.
  I need to: 
  <strong>Create a function that appends the name and email to the end of a named file.</strong></p>
  
  <p>Code i use:</p>
  
  <pre><code>    # Create a function that appends the name and email to the end of a named file.
  def addEmail(filename, name, email):
      f = open(filename, 'a') # replace the mode
      f.write("\n"+name+' '+email)
      # Append name and email, each record should end with '\n'.
      f.close()
      # close file
      return f # do not remove this line 
  </code></pre>
  
  <p>I get:
  <a href="https://i.stack.imgur.com/dSM08.png" rel="nofollow noreferrer">Error</a>
  I cant understand where is my mistake.Please help.</p>