Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8938355
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T10:36:21+00:00 2026-06-15T10:36:21+00:00

Firstly, I’m just learning Python (which is my first language) so, while I recognise

  • 0

Firstly, I’m just learning Python (which is my first language) so, while I recognise there are numerous websites that address this, I’ve spent a weekend trying to get my head around implementing a solution and got nowhere with it. So, I’m hoping someone here can help me 🙂

The problem is simple: I’ve created a list of lists in a Python program, and I need to output them to a *.csv file so I can import it into Excel etc.

The list looks like this:

[['title1','title2','title3'],['date1','info1','category1'],['date2','info2','category3'],...]

I’ve found solutions where the elements in each list are integers, I can’t get them to work with strings.

Any help on this would be much appreciated!

Thanks,

Adam

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T10:36:22+00:00Added an answer on June 15, 2026 at 10:36 am

    There’s a CSV module that can do this:

    import csv
    
    data = [['title1','title2','title3'],['date1','info1','category1'],['date2','info2','category3']]
    
    with open('stuff.csv', 'wb') as csvfile:
      writer = csv.writer(csvfile)
      for line in data:
        writer.writerow(line)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Firstly, this is not a question about repository synchronisation for which there are numerous
Firstly, I just want to say that the gmaps4rails gem has been fantastic. Easy
Firstly, is there a command for getting help and parameters for each sos command
Firstly, this is going to sound like homework, but it ain't. Just a problem
Firstly I realise that this is a familiar question, it seems to pop up
Firstly, let me say that I've been on this issue for pretty much 2
Firstly, YES, this is a duplicate issue that's been asked 100 times on here,
Firstly, I know that CSS expressions are defunct and wrong in so many ways,
Firstly, there are 3 separate images. A chick, the word 'delivery' and 'foodstant' I
Firstly yes i know that ints are more native than bytes and that all

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.