Question: JAVA Create an array of 100 integers randomly generated from 70 to 150 . Sort the array using Bubble Sort. Print the array after sorting
JAVA
Create an array of 100 integers randomly generated from 70 to 150 . Sort the array using Bubble Sort. Print the array after sorting
Count the number of comparisons and then print the number of comparisons and the computer time.
Also in another run of the program , change the bubble sort to efficient version and repeat the process (print the number of comparisons and the computer time).
Repeat the procedure again using the efficient bubble sort. Also be sure to leave comments within your code.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
