Question: Revise LinearSearch. java listing 7.6, page 266 (name it LinearSearch2), to return the indexes of all duplicated target keys. Design the main method of your

Revise LinearSearch. java listing 7.6, page 266 (name it LinearSearch2), to return the indexes of all duplicated target keys. Design the main method of your program such that it allows the user to re-run the program with different sets of inputs (i.e., use a loop). Document your code, and organize and space the outputs properly. Use escape characters and formatting objects when applicable. public class LinearSearch { /** The method for finding a key in the list */ public static int linearSearch(int[] list, int key) { for (int i = 0: i
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
