Write program to show percentage of calories come from fat

Assignment Help Programming Languages
Reference no: EM1368645

Write a program that asks the user to enter the number of calories and fat grams in a food item. The program should display the percentage of the calories that come from fat. One gram of fat has 9 calories, so:

(Calories from fat) = (fat grams) * 9

The percentage of calories from fat can be calculated as:

(Calories from fat) / (total calories)

If the calories from fat are less than 30% of the total calories of the food, it should also display a message indicating the food is low in fat.

Reference no: EM1368645

Questions Cloud

Explain when ginn realized that his jacket was still : Explain When Ginn realized that his jacket was still in the nightclub, he attempted to reenter the premises. He was met at the door by the manager
Explain common valuation approaches : Common valuation approaches-Which of the three most common valuation approaches do you think are most appropriate?
Economic opportunities : Should a country's income be distributed to its members according to their contributions to the members' requires? Should society attempt to equalize income/economic opportunities?
Important information about medical office procedures : Suggest a procedure to ensure timely billing and describe the importance of such procedures for timely billing and explain how timely billing relates to the medical office's cash flow.
Write program to show percentage of calories come from fat : Write a program which asks user to enter number of calories and fat grams in a food item. The program must display percentage of the calories that come from fat.
Explain ethical behavior can shift depending on situation : Explain Ethical behavior can shift depending on the situation and In order for an organization to eliminate unethical behavior, it will have a code of conduct in place
Show the inancial reporting : Why is it important to report discontinued operations or extraordinary items separately from income from continuing operations and is this method of reporting allowed? What concerns does this type of reporting create?
Compute net income : Carmen opens a retail store. Her sales during 1st year are $600,000, of which $30,000 has not been collected at the year end. Her purchases are $400,000.
Explain what are the pros and cons of each vendor : Explain What are the pros and cons of each vendor and What are some issues you would consider in making the decision to select a database vendor for an organization you work for?

Reviews

Write a Review

Programming Languages Questions & Answers

  Write a haskell program to calculates a balanced partition

Write a program in Haskell which calculates a balanced partition of N items where each item has a value between 0 and K such that the difference b/w the sum of the values of first partition,

  Create an application to run in the amazon ec2 service

In this project you will create an application to run in the Amazon EC2 service and you will also create a client that can run on local machine and access your application.

  Explain the process to develop a web page locally

Explain the process to develop a Web page locally

  Write functions

These 14 questions covers java class, Array, link list , generic class.

  Programming assignment

If the user wants to read the input from a file, then the output will also go into a different file . If the user wants to read the input interactively, then the output will go to the screen .

  Write a prolog program using swi proglog

Write a Prolog program using swi proglog

  Create a custom application using eclipse

Create a custom Application Using Eclipse Android Development

  Create a application using the mvc architecture

create a application using the MVC architecture. No scripting elements are allowed in JSP pages.

  Develops bespoke solutions for the rubber industry

Develops bespoke solutions for the rubber industry

  Design a program that models the worms behavior

Design a program that models the worm's behavior.

  Writing a class

Build a class for a type called Fraction

  Design a program that assigns seats on an airplane

Write a program that allows an instructor to keep a grade book and also design and implement a program that assigns seats on an airplane.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd