Question
This is a Java program 1) You've been hired by Snow Superstars to write a Java console application that calculates and shows the total and
This is a Java program
1) You've been hired by Snow Superstars to write a Java console application that calculates and shows the total and average snowfall for three winter months. Configure the application in your development tool to receive the following three program arguments:
Integer snowfall for month 1 in inches.
Integer snowfall for month 2 in inches.
Integer snowfall for month 3 in inches.
Loop through the arguments array and print the index and value of each argument. Convert each argument from string to integer using Integer.parseInt(args[n]) and calculate the total and average snowfall. Format the total and average snowfall in two columns using escape sequences. The first column is a label and the second column is a value with units. The output should look like this:
Print out of the code//////////////////////////////////////
Welcome to Snow Superstars
--------------------------
Index Argument
0 2
1 6
2 5
Total: 13 inch(es)
Average: 4.333333333333333 inch(es)
End of Snow Superstars.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started