From 153009ea9ebba0883c0d8bd7343bc7823370c5e8 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Sun, 13 Oct 2024 10:43:04 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- sorts/quantum_bogo_sort.py | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/sorts/quantum_bogo_sort.py b/sorts/quantum_bogo_sort.py index 8150a76d4..7bc8f8e4d 100644 --- a/sorts/quantum_bogo_sort.py +++ b/sorts/quantum_bogo_sort.py @@ -1,10 +1,11 @@ from typing import List + def quantum_bogo_sort(arr: List[int]) -> List[int]: """ Quantum Bogo Sort is a theoretical sorting algorithm that uses quantum mechanics to sort the elements. It is not practically feasible and is included here for humor. - + Reference: https://en.wikipedia.org/wiki/Bogosort#:~:text=achieve%20massive%20complexity.-,Quantum%20bogosort,-A%20hypothetical%20sorting @@ -14,17 +15,19 @@ def quantum_bogo_sort(arr: List[int]) -> List[int]: Example: >>> quantum_bogo_sort([2, 1, 4, 3]) [1, 2, 3, 4] - + >>> quantum_bogo_sort([10, -1, 0]) [-1, 0, 10] - + >>> quantum_bogo_sort([5]) [5] - + >>> quantum_bogo_sort([]) [] """ - return sorted(arr) # Sorting is assumed to be done instantly via quantum superposition + return sorted( + arr + ) # Sorting is assumed to be done instantly via quantum superposition if __name__ == "__main__":