From a04d5c5e1e17c60f7dae0c240ac78972e8a9bf2d Mon Sep 17 00:00:00 2001 From: Anup Kumar Panwar <1anuppanwar@gmail.com> Date: Fri, 26 Aug 2016 17:16:03 +0530 Subject: [PATCH] Revert "Update bubble_sort.py" --- sorts/bubble_sort.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sorts/bubble_sort.py b/sorts/bubble_sort.py index 2f14fd65f..3bacb306f 100644 --- a/sorts/bubble_sort.py +++ b/sorts/bubble_sort.py @@ -30,7 +30,7 @@ def bubble_sort(collection): [-45, -5, -2] """ length = len(collection) - for i in range(length-1): + for i in range(length): for j in range(length-1): if collection[j] > collection[j+1]: collection[j], collection[j+1] = collection[j+1], collection[j]