title: JSON Key and value to csv file in python
body: <p>Here is my file_t.JSON am writing from Request content to a csv/json file</p>
  
  <pre><code>{"w1":"R"}
  {"w2":"R2"}
  {"w3":"R3"}
  {"w4":"R4"}
  {"w5":"R5"}
  </code></pre>
  
  <p>I'm expecting that my code below should give me the below result Expecting output.csv</p>
  
  <pre><code>w1 r
  w2 R2
  w3 R3
  W4 R4
  w5 R5
  </code></pre>
  
  <p>Here is my code</p>
  
  <pre><code>import csv
  
  f1 = file ("output.csv","w")
  
  f2 = file ("file_t.JSON","rU")
  
  with open("file_t.JSON") as f:
      csvr = csv.reader(f, delimiter=' ')
      csvr.next()
      for rec in csvr:
          key, values_txt = rec
          values = values_txt.split(',')
          print key, values
          f1.write(values)
  </code></pre>
  
  <p>It is not printing, writing to the output file.</p>