Cardio Zone Unscramble

Download the following code, and get it to compile. The code I am giving you contains all the correct code but in a mixed-up order. Change only the order of the lines so that things work as expected.

Files Needed

(Do not re-type this program. Simply download a copy of the file by right-clicking and choosing "Save link as..." from the context menu. Save it into your normal code folder.)

Do not change any of the lines of code. Only change the order of the lines. (You may add blank lines if you want, but you may not add any other code.)

A person's "maximum" heart rate can be estimated by subtracting their age from 220. The "cardio zone" heart range ranges from 60% to 80% of their maximum heart rate.

What You Should See

Age: 42
The maximum heart rate for a 42-year-old is 178.
The "cardio zone" is from 107.0 to 142.0 bpm.



©2017 Graham Mitchell