1.
Create a list called
myList
with the following six items: 76, 92.3, “hello”, True, 4, 76. Begin with the empty list shown below, and add 6 statements to add each item, one per item. The first three statements should use the append method to append the item to the list, and the last three statements should use concatenation.Solution.
my_list = []
my_list.append(76)
my_list.append(92.3)
my_list.append("hello")
my_list = my_list + [True]
my_list = my_list + [4]
my_list = my_list + [76]
print(my_list)