MCPcopy Create free account
hub / github.com/TheAlgorithms/Python / __init__

Method __init__

graphs/minimum_spanning_tree_prims2.py:86–89  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

84 """
85
86 def __init__(self) -> None:
87 self.heap: list[tuple[T, int]] = []
88 self.position_map: dict[T, int] = {}
89 self.elements: int = 0
90
91 def __len__(self) -> int:
92 return self.elements

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected