Program that prompts the user to enter the birth rate

Assignment Help Programming Languages
Reference no: EM13948045

f P is the population on the first day of the year, B is the birth rate, and D is the death rate, the estimated population at the end of the year is given by the formula:

P + (B * P)/100 - (D * P)/100

The population growth rate is given by the formula:

B - D

Write a program that prompts the user to enter the starting population, birth and death rates, and n, the number f years. The program should then calculate and print the estimated population after n years. Your program must consist of the following functions:

a. growthRate: This function takes as its parameters the birth and death rate, and it returns the population growth rate.

b. estimatedPopuation: This function takes as its parameters the current population, population growth rate, and n, the number of years. It returns the estimated population after n years.

Your program should to accept a negative birth rate, negative death rate, or a population less than 2.

1539_Program_6B.jpg

Reference no: EM13948045

Questions Cloud

Calculate the mean and the standard deviation : When the machine is functioning correctly the company expects a mean of 10.00 mm and a standard deviation of 0.05 mm. The machine is overhauled when the variability (i.e. the SD) deviates from the norm by 50% or more. What do your results suggest ..
Stock market bubbles will impact consumers by encouraging : An economy at the top of a stock market bubbles will impact consumers by encouraging A. greater consumption of luxury goods and less saving. B. more work and delaying retirement. C. greater consumption of luxury goods and greater saving. D. more inve..
Describe the phenomenon of passivity : Briefly describe the phenomenon of passivity. Name two common types of alloy that passivate. Why does chromium in stainless steels make them more corrosion resistant in many en- vironments than plain carbon steels?
Business reported the changes in working capital : A house painting business had revenues of $17,600 and expenses of $10,600 last summer. There were no depreciation expenses. However, the business reported the following changes in working capital:
Program that prompts the user to enter the birth rate : This function takes as its parameters the current population, population growth rate, and n, the number of years. It returns the estimated population after n years.
What is the equivalent annual savings from the purchase : Gluon Inc. is considering the purchase of a new high pressure glueball. It can purchase the glueball for $110,000 and sell its old low-pressure glueball, which is fully depreciated, for $20,000. What is the equivalent annual savings from the purchase..
Explain why or why not if the statement is incorrect : Explain why or why not. If the statement is incorrect, how would you state it correctly?
Research on the theories of relationships and intimacy : This week you have read research on the theories of relationships, intimacy, love, social identity, self categorization, and social comparison. Now you will have a chance to showcase what you have learned by creating a recommendation based on this..
How does the portfolio fair compare to the s&p 500 : Your client has $50,000 to invest and you plan to invest 60% in the security with the highest expected return. What would be the characteristics of this portfolio be (E(R),S)?

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