Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Learn Data Structures and Algorithms with Golang

You're reading from   Learn Data Structures and Algorithms with Golang Level up your Go programming skills to develop faster and more efficient code

Arrow left icon
Product type Paperback
Published in Mar 2019
Publisher Packt
ISBN-13 9781789618501
Length 336 pages
Edition 1st Edition
Languages
Arrow right icon
Author (1):
Arrow left icon
Bhagvan Kommadi Bhagvan Kommadi
Author Profile Icon Bhagvan Kommadi
Bhagvan Kommadi
Arrow right icon
View More author details
Toc

Table of Contents (16) Chapters Close

Preface 1. Section 1: Introduction to Data Structures and Algorithms and the Go Language
2. Data Structures and Algorithms FREE CHAPTER 3. Getting Started with Go for Data Structures and Algorithms 4. Section 2: Basic Data Structures and Algorithms using Go
5. Linear Data Structures 6. Non-Linear Data Structures 7. Homogeneous Data Structures 8. Heterogeneous Data Structures 9. Dynamic Data Structures 10. Classic Algorithms 11. Section 3: Advanced Data Structures and Algorithms using Go
12. Network and Sparse Matrix Representation 13. Memory Management 14. Next Steps 15. Other Books You May Enjoy

Sorting

Sorting algorithms arrange the elements in a collection in ascending or descending order. Lexicographical order can be applied to a collection of characters and strings. The efficiency of these algorithms is in the performance of sorting the input data into a sorted collection. The best sorting algorithm time complexity is O(n log n). Sorting algorithms are classified by the following criteria:

  • Computational complexity
  • Memory usage
  • Stability
  • Type of sorting: serial/parallel
  • Adaptability
  • Method of sorting

In the following sections, we'll look at the different sorting algorithms, that is, bubble, selection, insertion, shell, merge, and quick.

Bubble

The bubble sort algorithm is a sorting algorithm that compares...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €18.99/month. Cancel anytime