Question
The manager of Willow Springs Health Club wants a program that allows her to enter the number of calories and grams of fat contained in
The manager of Willow Springs Health Club wants a program that allows her to enter the number of calories and grams of fat contained in a specific food. The program should calculate and display two values: the foods fat calories and its fat percentage. The fat calories are the number of calories attributed to fat and are calculated by multiplying the foods fat grams by the number 9; this is because each gram of fat contains nine calories. Thefatpercentageistheratioofthefoodsfatcaloriestoitstotalcalories.Youcalculatethe fat percentage by dividing the foods fat calories by its total calories and then multiplying theresultby100.Thefatpercentageshouldbedisplayedwithzerodecimalplaces.Createa Visual Basic Windows application. Use the following names for the solution and project, respectively: Willow Solution and Willow Project. Save the application in the ClearlyVB2012\Chap08 folder. Change the nameof the form file on your disk tofrmMain. vb. If necessary, change the forms name to frmMain. Create a suitable interface. Code the application. (Hint: When coding the application, keep in mind that division by zero will produce a run time error.) Save the solution and then start and test the application. Close the Code Editor window and then close the solution
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