Consider the following code, write a for enhanced loop to input the hours worked for each day declared in the enum list and print the sum of hours worked in all days. import java.util.Scanner; public...


IN JAVA


Consider the following code, write a for enhanced loop to input the hours worked for each day<br>declared in the enum list and print the sum of hours worked in all days.<br>import java.util.Scanner;<br>public class Demo {<br>enum Days {MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY}:<br>public static void main(String[] args)<br>{<br>Scanner input = new Scanner(System.in);<br>double hours = 0, sum = 0;<br>for ()<br>{<br>// write your code here<br>}<br>System.out.println(

Extracted text: Consider the following code, write a for enhanced loop to input the hours worked for each day declared in the enum list and print the sum of hours worked in all days. import java.util.Scanner; public class Demo { enum Days {MONDAY, TUESDAY, WEDNESDAY, THURSDAY, FRIDAY}: public static void main(String[] args) { Scanner input = new Scanner(System.in); double hours = 0, sum = 0; for () { // write your code here } System.out.println("Total hours work = }} + sum);

Jun 04, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here