
Day-9: Counting Sort
Counting Sort is a sorting algorithm that does not base on comparison of elements which makes it very efficient in terms of time when the elements’ range is not to big.
Counting Sort basically takes an array and counts the occurences of each and every one of the elements. Based on their occurance rate places them into the original array in correct order.
Time complexity: O(n+R) where R is the range of the elements
Here is the link of my C++ implementation of Counting Sort: Counting Sort