What is insertion sort. How it’s different from Selection sort and Bubble sort. I discussed selection sort and bubble in my previous posts. In this post i’ll discuss another sorting algorithm insertion sort.
Write a selection sort program in C. How selection sort algorithm works and what’s their time complexity.
What is Selection Sort
Selection sort is an in-place comparison sort. Like bubble sort time complexity of Selection sort is also O(n^2). It is not suitable for large elements.