Explore BrainMass

Sorting Algorithm in Java

Please assist so that I can complete the following:

You will create a program that runs a sorting algorithm on a set of randomized values. Your program should run the algorithm several times, to get the average time for each sorting technique.


1. Write a program using C++ or Java that will take in randomized values between 1 and 10,000, sorting 1,000, 10,000 and 100,000 items.

2. Run your program through a sorting algorithm to sort this information using two different sorting techniques. Find the average length of time that it takes by running the program at least five times for each sorting technique.

3. Read and follow the directions in Creating an Archive of Files in Materials below. Provide final source code for your faculty member to compile and run locally to test.

4. In a post to the discussion below, respond to the following questions about your results:

How does the algorithm you chose affect the result of the sort?
How do the algorithm techniques of fragmentation affect the end result of sorting through larger amounts?

© BrainMass Inc. brainmass.com August 17, 2018, 3:03 am ad1c9bdddf

Solution Summary

This solution provides a sorting algorithm written in Java.