title: Writing to csv with for loops
body: <p>I am trying to write a new row for each item in list_people with the name and age of the person. If there are 3 people in the list, my CSV should have 3 rows and 2 columns as shown below:</p>
  
  <pre><code>Joann  15
  Maria  13
  Peter  19
  </code></pre>
  
  <p>My CSV gives me 1 row and 6 columns as shown below: </p>
  
  <pre><code>Joann 15 Maria 13 Peter 19
  </code></pre>
  
  <p>Here is the code I am using. </p>
  
  <pre><code>row_lines=[] 
  
  for i in list_people:
  
      info = inspect.getmembers(i)
  
      name = info[1]
      row_lines.append(name)
      age = info[2]
      row_lines.append(age)
  
  with open('test.csv', 'w') as csvFile:
      writer=csv.writer(csvFile, delimiter=',', quotechar='|', quoting=csv.QUOTE_MINIMAL, lineterminator='\n')
      writer.writerow(row_lines)
  </code></pre>
  
  <p>What do I need to change so that it writes to a new row for each iteration of my loop (for each person in the list_people)?</p>