Question: how to solve CHALLENGE ACTIVITY 8.2.2: Printing array elements. Write three statements to print the first three elements of array run Times. Follow each statement
how to solve
CHALLENGE ACTIVITY 8.2.2: Printing array elements. Write three statements to print the first three elements of array run Times. Follow each statement with a newline. Ex: If run Time = (800, 775, 790, 805, 808}, print: 800 775 790 Note: These activities may test code with different test values. This activity will perform two tests, the first with a 5-element array (int runTimes[5]), the second with a 4-element array (int runTimes[4]). See How to Use zyBooks. Also note: If the submitted code tries to access an invalid array element, such as runTime[9] for a 5-element array, the test may generate strange results. Or the test may crash and report "Program end never reached", in which case the system doesn't print the test case that caused the reported message. Learn how our autograder works 686470.5454358.qx3zqy7 import java . util. Scanner; 1 test passed public class PrintRunTimes { public static void main (String args) { int runTimes = new int[5]; All tests passed // Populate array runTimes [0] = 800; 9 runTimes [ 1] = 775; 10 runTimes [ 2] = 790; 11 runTimes [3] = 805; 12 runTimes [4] = 808; 13 14 V* Your solution goes here * / 15 16 return; 17 RunStep by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
