Selection Sort, Bubble Sort, & Insertion Sort
Here's an overview of introductory sorting algorithms such as selection sort, bubble sort, and insertion sort.
We'll cover the following
What is sorting?
Sorting is any process of arranging items systematically. In computer science, sorting algorithms put elements of a list in a certain order.
The most frequently used orders are numerical (according to numbers) and lexicographical (according to letters). Efficient sorting is important for optimizing the efficiency of other algorithms which require sorted input or sort given input as part of their process.
Formal Definition
A list or array is sorted in ascending order if , such that , . Similarly, a list or array is sorted in descending order if , such that , .
Create a free account to view this lesson.
By signing up, you agree to Educative's Terms of Service and Privacy Policy