Question: CHALLENGE 5 . 4 . 2 : Iterating through arrays. 5 2 8 0 4 0 . 3 4 8 9 5 2 8 .
CHALLENGE
: Iterating through arrays.
Jump to level
Given the integer array dailyScores with the size of ARRVALS, write a for loop that sets sumBonus to the total bonus points. Scores above contain bonus points.
Ex: If the input is then the output is:
Bonus sum:
Note: To find a bonus point, the point is subtracted by the base point of
import java.util.Scanner;
public class ExtraSumalculator
public static void mainString args
Scanner scnr new Scanner
System.in;
final int ARRVALS ;
int dailyscores new int ARRVALS;
int ;
int sumBonus;
for dailyscores.length; i
dailyscores ;
Y your code goes here
System.out.printlnBonus sum: sumBonus;
Step 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
