Data Structures and Program Design Using Python: A Self-Teaching Introduction by Dheeraj Malhotra Neha Malhotra
Author:Dheeraj Malhotra, Neha Malhotra [Dheeraj Malhotra, Neha Malhotra]
Language: eng
Format: epub
Publisher: Mercury Learning and Information
Published: 2020-10-14T16:00:00+00:00
6.5INTRODUCTION TO SORTING
Sorting refers to the process of arranging the data elements of an array in a specified order, that is, either in ascending or descending order. For example, it is practically impossible for us to find a name in the telephone directory if the names in it are not in alphabetical order. However, the same can be true for dictionaries, book indexes, and bank accounts. Hence, the convenience of having sorted data is unquestionable. Retrieval of information becomes much easier when the data is stored in some specified order. Therefore, sorting is a very important application in computer science.
Let us take an array that is declared and initialized as
array = [10, 25, 17, 8, 30, 3]
Then, the array after applying the sorting technique is
array = [3, 8, 10, 17, 25, 30]
A sorting algorithm can be defined as an algorithm that puts the data elements of an array/ list in a certain order, that is, either numerical order or any predefined order. Many sorting algorithms are available and are widely used according to the different environments required by the different sorting methods.
The two basic categories of sorting methods are
1.Internal Sorting â This refers to the sorting of the data elements stored in the computerâs main memory.
2.External Sorting â This refers to the sorting of the data elements stored in the files. It is applied when the amount of data is large and cannot be stored in the main memory.
Download
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.
API Testing and Development with Postman by Dave Westerveld(3618)
Learning C# by Developing Games with Unity 2020 by Harrison Ferrone(2615)
Software Architecture for Busy Developers by Stéphane Eyskens(2322)
2021 Beginners Guide to Python Programming Language: A Crash Course to Mastering Python in One Hour by Elmer Gary & Elmer Gary(1884)
Machine Learning for Algorithmic Trading by Stefan Jansen(1628)
Hands-On ROS for Robotics Programming by Bernardo Ronquillo Japón(1572)
Delphi GUI Programming with FireMonkey by Andrea Magni(1457)
Game Development Projects with Unreal Engine by Hammad Fozi & Goncalo Marques & David Pereira & Devin Sherry(1402)
Cloud Native with Kubernetes by Alexander Raul(1374)
Datadog Cloud Monitoring Quick Start Guide by Thomas Kurian Theakanath(1346)
Software Architecture Patterns for Serverless Systems by John Gilbert(1338)
Practical Node-RED Programming by Taiji Hagino(1336)
Automate It with Zapier by Kelly Goss(1318)
Practical System Programming for Rust Developers by Prabhu Eshwarla(1312)
Delphi Programming Projects by William Duarte(1296)
Mastering React Test-Driven Development by Daniel Irvine(1290)
Developing Multi-Platform Apps with Visual Studio Code by Ovais Mehboob Ahmed Khan & Khusro Habib & Chris Dias(1253)
Ghidra Software Reverse Engineering for Beginners by A. P. David(1244)
Learn Spring for Android Application Development by S. M. Mohi Us Sunnat(1235)
