From 130b8f13a0c01dff5ba30450821151501e8689bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=B0lker=20O=C4=9Fulcan=20Say=C4=B1n?= <47698920+iosayin@users.noreply.github.com> Date: Mon, 5 Oct 2026 18:05:12 +0300 Subject: [PATCH] refactor(sorts): remove redundant TypeVar in pancake_sort --- sorts/pancake_sort.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/sorts/pancake_sort.py b/sorts/pancake_sort.py index 50eb8cc783f3..ddad6daf6704 100644 --- a/sorts/pancake_sort.py +++ b/sorts/pancake_sort.py @@ -21,16 +21,13 @@ """ from collections.abc import Sequence -from typing import Any, Protocol, TypeVar +from typing import Any, Protocol class Comparable(Protocol): def __lt__(self, other: Any, /) -> bool: ... -T = TypeVar("T", bound=Comparable) - - def pancake_sort[T: Comparable](arr: Sequence[T]) -> list[T]: """Sort Array with Pancake Sort.