Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C++ C# code Code 5 Proper Output 2 Discussion Questions 3 Total Question Write a program that asks for the number of calories and fat

image text in transcribed
image text in transcribed
C++
C# code Code 5 Proper Output 2 Discussion Questions 3 Total Question Write a program that asks for the number of calories and fat grams in a food. The program should display the percentage of calories that come from fat. If the calories from fat are less than 30% of the total calories of the food, it should also display a message indicating that the food is low in 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. Input Validation: Make sure the number of calories and fat grams are not less than 0. Also, the number of calories from fat cannot be greater than the total number of calories. If that happens, display an error message indicating that either the calories or fat grams were incorrectly entered. Sincerely, Dr. Rasha Shakir AbdulWahhan Dear 2019298138 I enclosed here a copy of your Assignment. Read the below instructions. The due date is on 28/12/2020 Submit your work on the available link on the blackboard Instructions for students: The due date to submit the Assignment is 28/12/2020 Week 12 at 12:00 PM and is worth 10% towards your Assignment mark for ITCR1106. Please, read it carefully and if you have any inquiry, then post your question in the discussion forum in BB system You need to send your solution using blackboard on or before the due date Week 12 28/12/2020 Do Not CUT - PASTE your content from other student answer. PLAGIARISM POLICY: Acts of Plagiarism, whether intentional or unintentional is not tolerated and you are strongly urged to refer to CAS Policy 006 and its Procedures for details on the consequences of plagiarism within the CAS system. Submission Guidelines Make sure your folder contains the following files. 1. Students submit the answer in a Microsoft Word file which contains- Your Name with Your ID The complete C++ source code of your question. Snapshots of your output 2. All C++ files related with your Project

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

Object Oriented Databases Prentice Hall International Series In Computer Science

Authors: John G. Hughes

1st Edition

0136298745, 978-0136298748

More Books

Students also viewed these Databases questions

Question

BPR always involves automation. Group of answer choices True False

Answered: 1 week ago