Relative Content

Tag Archive for algorithmsorting

Shell sort vs Insertion sort

I did not get why shell sort is more efficient.
so here is a comparison of both algos according to what I have understood:

Algorithm for sorting cards

I was assigned homework. Now I have 13 mixed cards I want to arrange in straight order first then four of kinds > three of kinds > pairs > the remaining cards . Do you have any ideas? Give me an idea

Does the Quick Select algorithm is in-placed?

I believe that the algorithm to find the k-th smallest element is in-place and my array also will be reshaped(k-th smallest element is at k index. left side is smaller and right side is bigger than k-th smallest). So this is my array shape after runing quick-select. why doesn’t it apply in pancake sort? When the k-th smallest element is found, the array is The array still has its original shape in each step?