DescriptionCSIT 254 – Programming Lab 02 – Searching / Sorting — Instructions
Due 6/12/2019 by 9:30
Download the ProgrammingLab02F18 project from Canvas.
In the ProgrammingLab02F18.java file, there are settings in the main method for:
final int MAX_VALUE = 1000000;
final int NUM_ELEMENTS = 10;
final int NUM_SEARCHES = 10;
final boolean DISPLAY_ARRAY = true;
final boolean DISPLAY_SEARCH_RESULTS = true;
First 2 runs – just look at output
For 10 elements and 10 searches, keep the booleans as true so you can see the output, and run the
program. Just look over the results
Then change the booleans to false, run, and look over the results
Change Settings, Run, record results, repeat
With the booleans as false, change the number of elements and number of searches as shown in the
table on the worksheet, run and record the nano times in the worksheet.
This worksheet is available as a Word document and an Excel Spreadsheet so you can record
your results into the table (copy/paste) and then load the document/spreadsheet into canvas
when done.
Record environment information
At the bottom of the results page, please enter information about your processor, OS, Java IDE.
For the last two runs, please make note of what applications you have open ( and how many tabs open
in a browser )
Worksheet is in Canvas
Number of
elements
(n)
Num
Searches
10
10,000
Total nano time
for linear
searches
0.00353964
Total nano time
for sort of n elements
0.00009951
Total nano time
for binary
searches
0.00240928
^^^^^^^^^^^^ see worksheet in Canvas ^^^^^^^^^^^^^^^^^^^
CSIT 254 – Programming Lab 02 – Searching / Sorting — Worksheet
Due 6/12/2019 by 9:30 pm
Name:
Number of
elements
(n)
Num
Searches
10
10,000
30
10,000
100
100,000
300
100,000
1,000
100,000
3,000
100,000
10,000
100,000
30,000
100,000
100,000
100,000
300,000
100,000
Total nano time
for linear
searches
Total nano time
for sort of n elements
Your guess for nano time for sort of 1,000,000 elements: ______________
Computer / Environment info:
Operating System:
Speed of processor (settings, system, about):
Java IDE:
For the last 2 runs, what other applications did
you have open
(example: Word, Chrome with 4 tabs)
Total nano time
for binary
searches
Purchase answer to see full
attachment