Skip to content

Commit 8abfbf1

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent be9ff5b commit 8abfbf1

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

data_structures/heap/skew_heap.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,12 @@
55
from collections.abc import Iterable, Iterator
66
from typing import Any, Protocol, TypeVar, runtime_checkable
77

8+
89
@runtime_checkable
910
class SupportsLessThan(Protocol):
1011
def __lt__(self, other: Any) -> bool: ...
1112

13+
1214
T = TypeVar("T", bound=SupportsLessThan)
1315

1416

@@ -198,6 +200,7 @@ def pop(self) -> T | None:
198200
)
199201

200202
return result
203+
201204
def top(self) -> T:
202205
"""
203206
Return the smallest value from the heap.

0 commit comments

Comments
 (0)