ObamtechNetworks / sorting_algorithms

A collaborative project about learning the different kinds of the sorting algorithms, Big O notation, time and space complexities and how to implement them
1 stars 0 forks source link

Task 4. Shell sort - Knuth Sequence #6

Open johnlivingprooff opened 9 months ago

johnlivingprooff commented 9 months ago

a function that sorts an array of integers in ascending order using the Shell sort algorithm, using the Knuth sequence

ObamtechNetworks commented 9 months ago

Ok let's check out it

ObamtechNetworks commented 9 months ago

Two checks having red <<<>>

johnlivingprooff commented 9 months ago

What do you think of this edge case:

if (!array || size < 2) return;