Fill in the blank
# adds 5 to the end of the list nums nums = [1, 2, 3] nums.____(5) # nums is now [1, 2, 3, 5]
Answer: append
append() adds a single element to the end of a list.
Play Problem Solving ▸
# adds 5 to the end of the list nums nums = [1, 2, 3] nums.____(5) # nums is now [1, 2, 3, 5]
Answer: append