[pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci
This commit is contained in:
pre-commit-ci[bot] 2023-10-05 15:01:10 +00:00
parent 1b83b6e4d5
commit 18c9a3388b

View File

@ -16,9 +16,7 @@ import random
from typing import Any from typing import Any
def partition(array: list, def partition(array: list, starting_index: int, ending_index: int) -> int:
starting_index: int,
ending_index: int) -> int:
""" """
Partition the array. Partition the array.
Args: Args:
@ -45,9 +43,7 @@ def partition(array: list,
return i + 1 return i + 1
def randomized_partition(array: list, def randomized_partition(array: list, starting_index: int, ending_index: int) -> int:
starting_index: int,
ending_index: int) -> int:
""" """
Randomized partition of the array. Randomized partition of the array.
Args: Args:
@ -71,10 +67,9 @@ def randomized_partition(array: list,
return partition(array, starting_index, ending_index) return partition(array, starting_index, ending_index)
def selection_sort(array: list, def selection_sort(
starting_index: int, array: list, starting_index: int, ending_index: int, smallest_element: int
ending_index: int, ) -> list | None | Any:
smallest_element: int) -> list | None | Any:
""" """
Returns a list of sorted array elements using selection sort. Returns a list of sorted array elements using selection sort.
Args: Args: