DSC-IIITL / GitGrind

9 stars 58 forks source link

Added a more optimized solution using Insertion Sort Algorithm for sorting.cpp issue #35 #52

Closed digvijay2406 closed 9 months ago

digvijay2406 commented 9 months ago

Here I have used the Insertion Sort Algorithm to find a more optimized solution of issue #35 sorting.cpp

It is a simple sorting algorithm that builds the final sorted array one element at a time, efficiently placing each element in its correct position within the sorted portion. It has a time complexity of O(n^2) and is suitable for small datasets.

Please review this @PavanaSakethaRam @Illuminati9 @Kota-Karthik @akhilender-bongirwar