-2

It's quiet simple - when I run this simple syntax in my text editor:

Syntax

Then the output is:

output

The problem is how can I remove the column to get this:

[csv create without python

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
  • 2
    Could you please edit your question and add your code in text format and not as images? This would make your question much easier to read. Thanks! – toti08 Jan 08 '19 at 08:45

1 Answers1

0

Open your file in binary mode: with open(file, 'w+b') as csv_file:

or set newline to empty string: with open(file, 'w+', newline='') as csv_file:

Source: https://stackoverflow.com/a/3191811/6685140

Sam Hollenbach
  • 652
  • 4
  • 19