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 9012343
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T02:58:17+00:00 2026-06-16T02:58:17+00:00

Recently in Python I have encountered this statement: board.append([‘ ‘] * 8) I have

  • 0

Recently in Python I have encountered this statement:

board.append([' '] * 8)

I have tried to search the Internet with Google to find some more information about this type of statement, but I can’t.

I know what the statement does, but I do not understand how, in what manner is doing, that.

This is the first time I have seen the * operator used on a list. Can you please refer me to a place where I can find some more information about this type of statements?

  • 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-16T02:58:19+00:00Added an answer on June 16, 2026 at 2:58 am

    Can you please refer me to a place where I can find some more information about this type of statements.

    Most of the relevant operators and methods are defined here: Sequence Types.

    Specifically s * n is defined as

    s * n, n * s — n shallow copies of s concatenated

    Here, s is a sequence and n is a number.

    Thus, [' '] * 8 returns a list consisting of eight ' '.

    board.append() appends the result to board, which presumably is a list (of lists).

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I recently learned Python (2.7) and have been making some simple board games with
I'm practising python and recently this problem crept up when I have invalid syntax
I have recently been going through some of our windows python 2.4 code and
Recently run into following problem using python 2.7: I have class like this: class
I've recently learned that python doesn't have the switch/case statement. I've been reading about
All, I've recently started doing some javascript coding. I have used the python-mode vim
I was recently trying to solve some task in Python and I have found
Perhaps I am getting rusty (have been writing in Python recently). Why does this
I have only started learning python recently. I would still be considered a beginner.
I have only started learning Python recently. Let me explain what I am trying

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.