The task of the append method is to add the element in the list and so is of method extend(). meaning code example
Example 1: python append vs extend
my_list = [23, 11, 42, 24523]
my_list.append([34523, 76979])
print(my_list)
my_list.extend([12, 99])
print(my_list)
"""
Output:
[23, 11, 42, 24523, [34523, 76979]]
[23, 11, 42, 24523, [34523, 76979], 12, 99]
"""
Example 2: python list extend not working
techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga techlux.ga