CSC 2200 Lecture Notes - Lecture 25: Lexicographical Order, Telephone Directory, Sorting Algorithm

12 views3 pages
CSC 2200 lecture 25
Sorting techniques
Sorting
o Refers to arranging data in particular format
o Specifies the way to arrange data in a particular order
o Most common orders are in numerical or lexicographical order
o The importance of sorting lies in the fact that data searching can be optimized to
a very high level
If data is sorted in a sorted manner
o Sorting is also used to represent data in more readable formats
Example
o Telephone directory
Sorted by names
o Dictionary
Alphabetical order
In place sorting and not in place sorting
o Sorting algorithm may require some extra space for comparison and temporary
storage of few data elements
o These algorithm do not require any extra space and sorting is said to happen in-
place
Within array itself
Unlock document

This preview shows page 1 of the document.
Unlock all 3 pages and 3 million more documents.

Already have an account? Log in

Get OneClass Notes+

Unlimited access to class notes and textbook notes.

YearlyBest Value
75% OFF
$8 USD/m
Monthly
$30 USD/m
You will be charged $96 USD upfront and auto renewed at the end of each cycle. You may cancel anytime under Payment Settings. For more information, see our Terms and Privacy.
Payments are encrypted using 256-bit SSL. Powered by Stripe.