Skip to content

Commit aa3131b

Browse files
committed
Add type annotations to circle_sort
1 parent 678dedb commit aa3131b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sorts/circle_sort.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"""
1010

1111

12-
def circle_sort(collection: list) -> list:
12+
def circle_sort(collection: list[int]) -> list[int]:
1313
"""A pure Python implementation of circle sort algorithm
1414
1515
:param collection: a mutable collection of comparable items in any order
@@ -30,7 +30,7 @@ def circle_sort(collection: list) -> list:
3030
if len(collection) < 2:
3131
return collection
3232

33-
def circle_sort_util(collection: list, low: int, high: int) -> bool:
33+
def circle_sort_util(collection: list[int], low: int, high: int) -> bool:
3434
"""
3535
>>> arr = [5,4,3,2,1]
3636
>>> circle_sort_util(lst, 0, 2)

0 commit comments

Comments
 (0)