Computers

Professional Development

Image

Python List, Tuple, Set & Dictionaries

779
plays

25 questions

Show Answers
See Preview
  • 1. Multiple Choice
    30 seconds
    1 pt

    Square brackets in an assignment statement will create which type of data structure?

    ( s=[] )

    List

    Queue

    Dictionary

    Set

  • 2. Multiple Choice
    30 seconds
    1 pt

    Which of these is the correct code for creating a list of names?

    nameList = John, Harry, Jesse, John, Harry, Harry

    nameList = ("John", "Harry", "Jesse", "John", "Harry", "Harry")

    nameList = ["John", "Harry", "Jesse", "John", "Harry", "Harry"]

    nameList = [John, Harry, Jesse, John, Harry, Harry]

  • 3. Multiple Choice
    30 seconds
    1 pt

    List items have an index number. In the following list, which item has the index number of 3?

    ["John", "Harry", "Jesse", "John", "Harry", "Harry"]

    "John"

    "Harry"

    "Jesse"

    "John"

  • Answer choices
    Tags
    Answer choices
    Tags

    Explore all questions with a free account

    Already have an account?