Question
To be done in C++ Zoo Food Calculator The purpose of this program is to determine the amount of food eaten by a certain kind
To be done in C++
Zoo Food Calculator
The purpose of this program is to determine the amount of food eaten by a certain kind of animal. Rather than using one big pile of main( ), you need to use functions for these calculation that incorporate pass-by-value parameters. In addition, you need to include various int or double const declarations within your program. Finally, embed your program in a loop so that the calculation can be repeated as often as the user wishes.
IN ORDER TO RECEIVE FULL CREDIT, YOU MUST DEFINE AND CALL FUNCTIONS AND PASS ARGUMENTS.
You should base your calculations on the following table:
Mammals | Amphibians | Reptiles | ||
1 lb for each 10 lbs in weight | 2/3 lb for each 5 lbs in weight | 1/5 lb for each 6 lbs in weight | ||
1/3 lb for each foot in height | 1/4 lb for each 6 inches in length | 1/2 lb for each foot in length | ||
1/10 lb for each 5 years of age | 1/5 lb for each 4 years in age | Deduct 10% of food during winter | ||
Add an extra 15% of food if the animal can run faster than a human | Add an extra 10% of food if the animal is pregnant |
The following program dialogue should help you figure out what kind of program I am looking for.
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