Computers and Technology

Java Eclipse Homework JoggerPro Over a seven day period, a jogger wants to figure out the average number of miles she runs each day.

Use the following information to create the necessary code. You will need to use a loop in this code.

The following variables will need to be of type “double:”
miles, totalMiles, average

Show a title on the screen for the program.
Ask the user if they want to run the program.
If their answer is a capital or a lowercase letter ‘Y’, do the following:
Set totalMiles to 0.
Do seven times (for loop)
{

Show which day (number) you are on and ask for the number of miles for this day.
Add the miles to the total
}

Show the total number of miles
Calculate the average
Show the average mileage with decimals
Use attractive displays and good spacing.
Save your completed code according to your teacher’s directions.

answer
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 23.06.2019 01:00, lusciousl
Petrică, tânăr licean în clasa a ix-a, a primit în dar de la părinţii săi un cont bancar pentru micile sale cheltuieli curente. el este pasionat de internet banking şi îşi verifică cu grijă toate tranzacţiile efectuate. pentru creşterea securităţii tranzacţiilor online, banca îi furnizează lui petrică un număr pe care el va trebui să îl modifice, obţinând un număr tan – număr de autentificare a tranzacţiei (transaction authentication number). regula de obţinere a numărului tan este următoarea: se formează cel mai mic număr par din toate cifrele numărului furnizat de bancă. cerinţă cunoscând numărul n furnizat de bancă, să se determine numărul tan obţinut de petrică. date de intrare fişierul tan. in conţine pe prima linie numărul natural n cu semnificaţia din enunţ. date de ieşire fişierul de ieşire tan. out va conţine o singură linie pe care va fi scris numărul tan cerut. restricţii • 0 < n < 18*1018 • n are cel puţin o cifră pară • numărul tan obţinut nu poate conţine zerouri nesemnificative
Answers: 2
image
Computers and Technology, 23.06.2019 22:40, azariah7
22. sata3 allows for data transfer rates of 600 mb/s. explain why you would likely not be able to copy data from one hard drive to another at anywhere close to this speed. also, what could be upgraded on the computer to achieve transfer speeds closer to 600 mb/s
Answers: 1
image
Computers and Technology, 23.06.2019 23:30, huangjianhe135
The keyboard usually has six rows of keys. which of the following is not one of the key group categories? letter keys number keys control keys graphic keys
Answers: 1
image
Computers and Technology, 24.06.2019 08:00, nataliamontirl4230
Java the manager of a football stadium wants you to write a program that calculates the total ticket sales after each game
Answers: 1
Do you know the correct answer?
Java Eclipse Homework JoggerPro Over a seven day period, a jogger wants to figure out the average n...

Questions in other subjects:

Konu
Physics, 15.12.2019 02:31