Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Can someone help me with this small Visual Basic program? Thank you. Instructions Write a program to analyze calories from fat. See both figures below

Can someone help me with this small Visual Basic program? Thank you.

image text in transcribed

Instructions Write a program to analyze calories from fat. See both figures below for two different possible outcomes for this program. The American Heart Association suggests that at most 30% of the calories in our diet come from fat. Although food labels give the number of calories and amount of fat per serving, they often do not give the percentage of calories from fat. This percentage can be calculated by multiplying the number of grams of fat in one serving by 9 and dividing that number by the total number of calories per serving. Write a program that requests the name, number of calories per serving, and the grams of fat per serving as input, and tells whether the food meets the American Heart Association recommendation. Nutrition | Nutrition Name of food: Lowfat milk Name of food: Oatmeal Calories per serving: 120 Grams of fat per serving: 5 Calories per serving: 117 Grams of fat per serving:3 Compute % Calories from Fat Compute % Calories from Fat Lowfat mik contains 37.50% calories from fat which exceeds AHA recommendation. Oatmeal contains 23.08% calories from fat which meets AHA recommendation

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database 11g SQL

Authors: Jason Price

1st Edition

0071498508, 978-0071498500

More Books

Students also viewed these Databases questions