Skip to content

Commit 551774e

Browse files
author
Christian Bender
committed
correct name again
1 parent 5fc4641 commit 551774e

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

allalgorithms/sorting/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from .insertion_sort import insertion_sort
33
from .selection_sort import selection_sort
44
from .bubble_sort import bubble_sort
5-
from .pidgeonhole_sort import pidgeonhole_sort
5+
from .pigeonhole_sort import pigeonhole_sort
66
from .stooge_sort import stooge_sort
77
from .cocktail_shaker_sort import cocktail_shaker_sort
88
from .tree_sort import tree_sort

allalgorithms/sorting/pidgeonhole_sort.py renamed to allalgorithms/sorting/pigeonhole_sort.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
# Github: @martmists
88
#
99

10-
def pidgeonhole_sort(data):
10+
def pigeonhole_sort(data):
1111
minimum = min(data)
1212
size = max(data) - minimum + 1
1313
holes = [0] * size

tests/test_sorting.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
insertion_sort,
66
merge_sort,
77
selection_sort,
8-
pidgeonhole_sort,
8+
pigeonhole_sort,
99
stooge_sort,
1010
cocktail_shaker_sort,
1111
tree_sort
@@ -26,7 +26,7 @@ def test_selection_sort(self):
2626
self.assertEqual([-44, 1, 2, 3, 7, 19], selection_sort([7, 3, 2, 19, -44, 1]))
2727

2828
def test_pigeonhole_sort(self):
29-
self.assertEqual([-44, 1, 2, 3, 7, 19], pidgeonhole_sort([7, 3, 2, 19, -44, 1]))
29+
self.assertEqual([-44, 1, 2, 3, 7, 19], pigeonhole_sort([7, 3, 2, 19, -44, 1]))
3030

3131
def test_stooge_sort(self):
3232
self.assertEqual([-44, 1, 2, 3, 7, 19], stooge_sort([7, 3, 2, 19, -44, 1]))

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy