ID EN
Collections

UserList

Python 3.11

Class that simulates a list. The instance’s contents are kept in a regular list, which is accessible via the data attribute of UserList instances. The instance’s contents are initially set to a copy of list, defaulting to the empty list []. list can be any iterable, for example a real Python list or a UserList object.

Syntax

PYTHON
class collections.UserList([list])

See Also

data UserList UserList UserList list UserList