clear()
The clear()
method removes all items from your collection, regardless of the initial state. This is useful when you need to empty the collection completely.
The clear()
method removes all items from your collection, regardless of the initial state. This is useful when you need to empty the collection completely.