Question: 7. For java please: Create an array of 10 integers containing the following values (in this order): 12, -7, 3, 17, 42, 6, 18,-15, 0,

7. For java please:  7. For java please: Create an array of 10 integers containing

Create an array of 10 integers containing the following values (in this order): 12, -7, 3, 17, 42, 6, 18,-15, 0, 1. Ask the user to enter an integer key value and print the array slot that the key was found in, or that the key was not found. Test Cases: Test Case 1: Enter a number to search for: 17 was found in array slot 3 Test Case 2: Enter a number to search for: 12 was found in array slot 0. Test Case 3: Enter a number to search for: 1 was found in array slot 9. Test Case 4: Enter a number to search for: 40 was not found

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!