Question: Create a program called AverageAgeYourLastName. In your program, create 4 - 6 integer variables that hold ages of people in your family. Assign those variables

Create a program called AverageAgeYourLastName. In your program, create 4-6 integer variables that hold ages of people in your family. Assign those variables a value. Perform a basic calculation to find the average age between the 4-6 variables (in case you can't remember how to figure out the average of numbers, here is a referenceLinks to an external site.). Double check your calculations to make sure you're using the correct data type (ages should be ints and the average age should be a double - you'll have to use casting!). The Casting Video at minute 2:20 reviews this. Do not change the integer datatypes for the ages. Print the results to the console with an explanation of what the user is seeing. For example, the console might say:
Jesse's age is 46.
Danny's age is 48.
Joey's age is 37.
Stephanie's age is 18.
Michelle's age is 13.
The average age is 32.4 years old.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!