Sorting Algorithms Introduction
Published: 2022-12-27 15:10:17

---
title: Sorting Algorithms Introduction
published: true
date: 2022-01-21 15:28:34 UTC
tags: 
canonical_url: https://sree-gaya3.hashnode.dev/sorting-algorithms-introduction
---

Hello Guys👋 I Hope you are doing great !! This is a short article, and in this, you will get a brief introduction to sorting algorithms.

Without Further Ado, Let's get started 👍!!

## Introduction

Sorting is nothing but an arrangement of elements in an ordered sequence like highest to lowest or lowest to highest or some alphabetical order.

These are some common sorting algorithms that we will discuss in this series.

1. Bubble Sort
2. Selection Sort
3. Insertion Sort
4. Merge Sort
5. Counting Sort
6. Quick Sort

Before going into each algorithm, let's first know some factors on which sorting algorithms are classified.

#### Classification of Sorting Algorithms

- **In-place sorting:** These algorithms do not require any extra space for comparison and temporary storage of a few data elements. It only needs the input space, excluding the constant space used for variables or iterators and the space used for stack in the recursive algorithms.   
_Examples:_ Bubble Sort, Selection Sort, Insertion Sort, Quicksort, etc.

- **Out-place sorting:** These algorithms require extra space for sorting  
_Examples:_ Merge Sort, Counting Sort, etc.

- **Stable sorting:** In these algorithms, two objects with equal keys appear in the same order before and after sorting  
_Examples:_ Bubble Sort, Insertion Sort, Merge Sort, Counting Sort, etc.

- **Un-stable sorting:** In these algorithms, two or more objects with equal keys don't appear in the same order before and after sorting  
_Examples:_ Selection Sort, Quick Sort, etc.

- **Adaptive sorting:** In these algorithms, the order of occurrence of elements in the input affects the time complexity of a sorting algorithm  
_Examples:_ Bubble Sort, Insertion Sort, Quick Sort, etc.

- **Non-adaptive sorting:** In these algorithms, the order of occurrence of elements does not affect the time complexity of a sorting algorithm  
_Examples:_ Selection Sort, Merge Sort, etc.

- **Comparision sorting:** These algorithms compare elements at each step of the algorithm to determine if one element should be to the left or right of another element.  
_Examples:_ Bubble Sort, Selection Sort, Insertion sort, Merge Sort, etc.

- **Integer sorting:** These type of algorithms do not make comparisons. Integer sorts determine for each element x, how many elements are less than x. This type of algorithm is used to immediately place each element into the correct slot no need to rearrange lists.  
_Example:_ Counting Sort

Here is the Complexity's of Different Sorting Algorithms

![screenshot of BigOCheetSheet](https://cdn.hashnode.com/res/hashnode/image/upload/v1642772867704/W6NOMfpP6.jpeg)

## 🖐Conclusion

Finally, In this article, we learned about some classifications of sorting algorithms. Now we are ready for learning algorithms 👍👩🎓

**What's Next**?

Thank you for reading so far🙏. I hope you enjoyed following it and are ready to learn sorting algorithms.

In the coming parts, we will discuss **about each Sorting Algorithm** in detail !! So Stay Tuned👀👀!!!!

Do share your valuable suggestions and your honest feedback. If you have any comments, questions, or concerns, Do comment them, and I am more than happy to take them💬.

Happy Learning 😊👍!!