An application that will interact with the user by inputting workout information

$17.00

Category:

Description

• Objective: Become familiar with C++ syntax. Become familiar with writing functions.
• Overview: This application will interact with the user by inputting workout information and then processing that information and displaying the results to the user.

Write a program that will:

1) Welcome the User to your app

2) Prompt the user for the number of steps walked/or ran during a workout (integer)

3) Prompt the user for their average stride length in inches (double)

4) Invoke a function called “convertDistance”
a) Function will have two arguments
i) Steps walked
ii) Stride Length
b) Calculate the distance of the workout to miles (1 mile = 63360 inches, define a c++ constant to use this value)
c) Function will return Distance in Miles a double

5) Invoke a function called “printWorkout”
a) Function will have three arguments
i) Steps walked
ii) Stride Length
iii) Distance in miles
b) Display all the data
i) Steps walked
ii) Stride Length (display 2 decimals)
iii) Miles covered (display 3 decimals)
b) Function will not return anything

6) Keeps a running total of distance covered in miles

7) Keeps the length of the longest workout in miles

8) Prompt the user to enter another workout

9) If another workout is to be entered then repeat steps 2 -8.

10) If no more workouts are to be entered, then
a) Invoke a function called printWrapUp
i) Function will have 2 arguments
(1) Total in Miles of all Workouts
(2) Longest Single Workout
ii) Display the
(1) Total in Miles of all workouts
(2) longest single workout

11) Thank the user.

Follow good programming and readability guidelines as covered in class.