Python - List Methods

Python - List Methods


The Python has a number of methods and functions that are available for use with lists. These methods and functions are listed below in alphabetical order. For more details about any one of these, please visit its page.

List Methods & Functions
MethodsDescription
Adds a specified element to the end of the list
The Python has a number of methods and functions that are available for use with lists. These methods and functions are listed below in alphabetical order. For more details about any one of these, please visit its page. Deletes all elements from the list
Creates a copy of the list into a new list
Returns the number of occurrence of a specified element in the list
List Methods & Functions Adds an element or iterable at the end of the list
Returns the index of first occurrence of a specified element in the list
Methods Adds a specified element at specified index in the list
Description Deletes an element at specified index or last element of the list
Deletes first occurrence of a specified element in the list
append() Reverses order of all elements in the list
Sorts elements of the list in ascending or descending order with specified sorting criteria
FunctionsDescription
Adds a specified element to the end of the list Returns total number of elements in the list
List function/constructor is used to create list from iterable like list, tuple, set, string and dictionary, etc.



Recommended Pages

  • clear()
  • Deletes all elements from the list
  • copy()
  • Creates a copy of the list into a new list