Python set.remove() Method
The remove() method removes the specified element from the set.
This method raises an error if the specified element does not exist.
Syntax
set.remove(elmnt)
Parameters
| Parameter | Description |
|---|---|
elmnt |
Required. The element to remove from the set |
Return Value
None.
Example
Using the remove() method:
Output
Click Run to execute your code
Enjoying these tutorials?