Question
A bag of chips has about 100 chips. The calories information on the bag claims that there are 10 servings in the bag, and each
A bag of chips has about 100 chips. The calories information on the bag claims that there are 10 servings in the bag, and each serving has 50 calories. Write a program that allows a user to enter the number of chips he/she consumed and outputs the equivalent in number of calories.
The program should also give the user some interesting feedback: If the calories consumed are less than 85 the program should also output Good!, if the calories count is higher than 100 and less than 150, the program should say High intake just from chips! and if the calories are higher than 150, it should say Enough chips for the day please!.
Provide executions for 15 chips, 25 chips and 90 chips.
The program should keep soliciting input from the user and doing the computations until the user says to quit.
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