collections
¶
Source code: collections.seq
- class collections.deque[T]¶
Properties:
Magic methods:
- __init__(arr: Array[T], head: int, tail: int, maxlen: int)
- __init__()
- __init__(maxlen: int)
- __init__(it: Generator[T])
- __bool__()
- __len__()
- __iter__()
- __contains__(x: T)
- __copy__()
- __str__()
- __getitem__(idx: int)
Methods:
- class collections.Counter[T]¶
Magic methods:
- __init__(elements: Generator[T])
- __init__(other: Counter[T])
- __init__(other: Dict[T, int])
- __getitem__(key: T)
- __delitem__(key: T)
- __eq__(other: Counter[T])
- __ne__(other: Counter[T])
- __copy__()
- __iadd__(other: Counter[T])
- __isub__(other: Counter[T])
- __iand__(other: Counter[T])
- __ior__(other: Counter[T])
- __pos__()
- __neg__()
- __add__(other: Counter[T])
- __sub__(other: Counter[T])
- __and__(other: Counter[T])
- __or__(other: Counter[T])
Methods:
- collections.namedtuple()¶