Question: This program is in Java The sort method for this program is quick sort You are to write an algorithm for the assigned sort method.

This program is in Java

The sort method for this program is quick sort

You are to write an algorithm for the assigned sort method. Then you are to write a program that reads a file and loads the file into an array. You will then sort the array using the method you were assigned. Once it is sorted, your program should ask the user to enter a value to search for and it should display a message indicating whether the item is stored in the array.

1. Create a text file to be read in

2. Storage class

instance variables: an array, integer variable that stores the size

readFile method- reads the file and then loads the file into the array

sort method- sorts the array using the assigned method

search method- receives a value to be evaluated and searches the array for that value. It returns true or false, indicating whether the value was found

3. Driver class- This class will do the following:

Asks the user for the name of the input file and then passes the file to the readFile method in the Storage Class

Call the sort method to sort the array

Asks the user for a search value and then calls the search method, outputting the result

You may write your program on any topic that you choose.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!