Python List remove() Method

Example

Delete the "banana" element from the fruits list:

fruits = ['apple', 'banana', 'cherry']
fruits.remove("banana")

Run Instance

Definition and Usage

The remove() method has the first element with the specified value.

Syntax

list.remove(element)

Parameter Value

Parameter Description
element Required. Any element of any type (string, number, list, etc.) to be deleted.