CSC108H1 Quiz: Study Guide - Practice Quiz 04 - Lists
![](https://new-preview-html.oneclass.com/dgvaz5r0qPOlmewVJ97ENReGJLbVnA4K/bg1.png)
Practice Quiz 04: Lists
1. Print the output of the following code.
my_list = [1, 2, 3, 4]
print(my_list)
my_list[1] = 3
print(my_list)
2. Print the output of the following code.
my_list = ['a', 'b', 'c', 'd']
print(my_list)
my_list[1] = ['e', 'f']
print(my_list)
3. Print the output of the following code.
my_list = [[1, 2], [['#', 4, [5, 6], 7], 'dogs', [[[True, False]]], 1], 8]
print(len(my_list))
print(my_list[1][1])
print(my_list[1][2][0])
4. Print the output of the following code.
my_list = [1, 1]
print(my_list)
my_list[0] = my_list[:]
my_list[1] = my_list[:]
print(my_list)
find more resources at oneclass.com
find more resources at oneclass.com
![CSC108H1 Full Course Notes](https://new-docs-thumbs.oneclass.com/doc_thumbnails/list_view/2218826-class-notes-ca-utsg-csc-108h1-lecture1.jpg)
21
CSC108H1 Full Course Notes
Verified Note
21 documents