Convert JSON to CSV using Python (Idle)

前端 未结 4 1435
旧巷少年郎
旧巷少年郎 2021-02-14 06:31

I have a JSON file of Latitude/Longitude that I want to covert to a CSV file. I want to do this using Python. I have read/tried all other stackoverflow and google search results

4条回答
  •  既然无缘
    2021-02-14 07:07

    Loop over the list one by one, and write out the field names explicitly is perhaps the simplest for this case.

    for row in x:
        f.writerow( [row['longitude'], row['latitude']] )
    

提交回复
热议问题