Skip to content

Commit 215c1f0

Browse files
authored
refactor(sorts): remove redundant TypeVar in pancake_sort (#15503)
1 parent 0e071f6 commit 215c1f0

1 file changed

Lines changed: 1 addition & 4 deletions

File tree

‎sorts/pancake_sort.py‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,13 @@
2121
"""
2222

2323
from collections.abc import Sequence
24-
from typing import Any, Protocol, TypeVar
24+
from typing import Any, Protocol
2525

2626

2727
class Comparable(Protocol):
2828
def __lt__(self, other: Any, /) -> bool: ...
2929

3030

31-
T = TypeVar("T", bound=Comparable)
32-
33-
3431
def pancake_sort[T: Comparable](arr: Sequence[T]) -> list[T]:
3532
"""Sort Array with Pancake Sort.
3633

0 commit comments

Comments
 (0)