From 62a4ea5165617bf8f0472b1d5f1cbaf504d0a943 Mon Sep 17 00:00:00 2001 From: Grant Sanderson Date: Sat, 21 Sep 2024 12:15:29 -0400 Subject: [PATCH] Update description of remove_list_redundancies --- manimlib/utils/iterables.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manimlib/utils/iterables.py b/manimlib/utils/iterables.py index e213cd91..854067cb 100644 --- a/manimlib/utils/iterables.py +++ b/manimlib/utils/iterables.py @@ -16,7 +16,7 @@ if TYPE_CHECKING: def remove_list_redundancies(lst: Sequence[T]) -> list[T]: """ - Used instead of list(set(l)) to maintain order + Remove duplicate elements while preserving order. Keeps the last occurrence of each element """ return list(reversed(dict.fromkeys(reversed(lst))))