Homework Help for C

May 3rd, 2015
Steve1995
Category:
Computer Science
Price: $5 USD

Question description

Write a C++ program to estimate the springtime count of deer in a park for 10 consecutive years.  

The population of any given year depends on the previous year's population according to the following calculation:   If the lowest winter temperature was less than 0 degrees, the deer population drops by 15%.   If the lowest winter temperature was between 0 degrees F and 25 degrees F (inclusive), the deer population drops by 10%.   If the lowest winter temperature was between 26 degrees F and 30 degrees F (inclusive), the deer population doesn’t change.   If the lowest winter temperature was between 31 degrees F and 35 degrees F (inclusive), the deer population rises by 12%.   If the lowest winter temperature was higher than 35 degrees F, the deer population rises by 14%.  

Input: The program should accept a starting year from the user, along with the initial deer population. For each subsequent year in the simulation, the program should prompt the user to enter the lowest winter temperature.  

Output: The program should print the calendar year and the population during the spring.  

A partial example of running such a program is shown below, with the user's input shown in italics.  

== Deer population simulation program ==  Please enter the starting year.  1985  Please enter the starting population for the deer.  150  What was the lowest winter temperature in 1985?  -10  In spring 1985, the deer population is 127.  What was the lowest winter temperature in 1986?  25  In spring 1986, the deer population is 114.  What was the lowest winter temperature in 1987?  36  In spring 1987, the deer population is 129.  ...  

You need to do the calculations for exactly 10 years (i.e. The program should ask for 10 temperatures and output 10 populations in total). Note that the deer population cannot be decimal.  


Tutor Answer

(Top Tutor) Daniel C.
(997)
School: Cornell University
PREMIUM TUTOR

Studypool has helped 1,244,100 students

8 Reviews


Summary
Quality
Communication
On Time
Value
pmallory
Dec 11th, 2016
" Totally impressed with results!! :-) "
mixedballz
Dec 2nd, 2016
" excellent work as always thanks for the help "
Five Star Tutor
Nov 26th, 2016
" Outstanding Job!!!! "
kiln82
Nov 18th, 2016
" awesome work thanks "
darnay
Nov 9th, 2016
" The best tutor out there!!!! "
likeplum4
Nov 5th, 2016
" Excellent work as usual "
kpcutie
Oct 13th, 2016
" Excellent job "
Joemoe
Oct 4th, 2016
" <3 it, thanks for saving me time. "
Ask your homework questions. Receive quality answers!

Type your question here (or upload an image)

1825 tutors are online

Brown University





1271 Tutors

California Institute of Technology




2131 Tutors

Carnegie Mellon University




982 Tutors

Columbia University





1256 Tutors

Dartmouth University





2113 Tutors

Emory University





2279 Tutors

Harvard University





599 Tutors

Massachusetts Institute of Technology



2319 Tutors

New York University





1645 Tutors

Notre Dam University





1911 Tutors

Oklahoma University





2122 Tutors

Pennsylvania State University





932 Tutors

Princeton University





1211 Tutors

Stanford University





983 Tutors

University of California





1282 Tutors

Oxford University





123 Tutors

Yale University





2325 Tutors