File tree 2 files changed +4
-1
lines changed
2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change 250
250
* [ Sum Of Subset] ( https://github.com/TheAlgorithms/Python/blob/master/dynamic_programming/sum_of_subset.py )
251
251
252
252
## Electronics
253
+ * [ Electric Power] ( https://github.com/TheAlgorithms/Python/blob/master/electronics/electric_power.py )
253
254
* [ Ohms Law] ( https://github.com/TheAlgorithms/Python/blob/master/electronics/ohms_law.py )
254
255
255
256
## File Transfer
Original file line number Diff line number Diff line change 9
9
For manual testing run:
10
10
python pigeon_sort.py
11
11
"""
12
+ from typing import List
12
13
13
14
14
- def pigeon_sort (array ) :
15
+ def pigeon_sort (array : List [ int ]) -> List [ int ] :
15
16
"""
16
17
Implementation of pigeon hole sort algorithm
17
18
:param array: Collection of comparable items
@@ -52,6 +53,7 @@ def pigeon_sort(array):
52
53
53
54
if __name__ == "__main__" :
54
55
import doctest
56
+
55
57
doctest .testmod ()
56
58
user_input = input ("Enter numbers separated by comma:\n " )
57
59
unsorted = [int (x ) for x in user_input .split ("," )]
You can’t perform that action at this time.
0 commit comments