From e0211794da527caaa0e3621fa4a8ae60eed3c547 Mon Sep 17 00:00:00 2001 From: nandujkishor Date: Fri, 13 Oct 2017 20:33:40 +0530 Subject: [PATCH] Changed the typographical error (#132) Changed the typo in line 113 and 115 regarding recursive binary search algorithm, found by a user who commented in comments. --- searches/binary_search.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/searches/binary_search.py b/searches/binary_search.py index 8dc3008daae3..5ef0a03215db 100644 --- a/searches/binary_search.py +++ b/searches/binary_search.py @@ -113,7 +113,7 @@ def binary_search_by_recursion(sorted_collection, item, left, right): return binary_search_by_recursion(sorted_collection, item, left, midpoint-1) else: return binary_search_by_recursion(sorted_collection, item, midpoint+1, right) - + def __assert_sorted(collection): """Check if collection is sorted, if not - raises :py:class:`ValueError`