Skip to content
/ sorting Public

This repository contains a list of different types of sorting techniques

Notifications You must be signed in to change notification settings

pratil/sorting

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sorting Techniques

This repository contains a list of different types of sorting techniques:

On the other hand, I have compared all the types of sorting techniques. The type of comparison that we can see here is:

  1. Testing all the types of a sort on a random array.
  2. Testing all the types of sorting on N randomly generated array and taking out average.

To compare and to calculate the time taken by them we need some more small classes which are:

  • Timer (To capture time taken to perform any task in nanoseconds)
  • Shuffle (To generate a random array for a given length)
  • Stats (To store all times and calculate an average value from it)
  • CompareSorts (To compare between different sorting techniques on a random array)
  • Test (To run a single/multiple sorts on N random arrays of a given size and keep their average)
  • Sort (An interface that works as the parent for all the sort types)
  • ArraySort (A class that used to duplicate Java's array sort as a child of Sort)
  • Order (An enum to decide in which order we want to sort the array)

Average Time Taken by Sort method to sort 100 random arrays of the given size

About

This repository contains a list of different types of sorting techniques

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages