Skip to content

Commit 41b420e

Browse files
committed
Resolving problems
1 parent 66324f8 commit 41b420e

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

pydatastructs/linear_data_structures/algorithms.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -1906,8 +1906,9 @@ def radix_sort(array, comp=lambda u, v: u <= v, **kwargs):
19061906
start = kwargs.get('start', 0)
19071907
end = kwargs.get('end', len(array) - 1)
19081908

1909-
# Handle sub-array selection if start and end are provided
1910-
sub_array = array[start:end+1]
1909+
sub_array = []
1910+
for i in range(start, end + 1):
1911+
sub_array.append(array[i])
19111912

19121913
# Remove None values from sub_array before sorting
19131914
sub_array = [x for x in sub_array if x is not None]

0 commit comments

Comments
 (0)