subject

5.11: population write a program that will predict the size of a population of organisms. the program should ask the user for the starting number of organisms, their average daily population increase (as a percentage, expressed as a fraction in decimal form: for example 0.052 would mean a 5.2% increase each day), and the number of days they will multiply. a loop should display the size of the population for each day. input validation. do not accept a number less than 2 for the starting size of the population. if the user fails to satisfy this print a line with this message "the starting number of organisms must be at least 2.", display the prompt again and try to read the value. similarly, do not accept a negative number for average daily population increase, using the message "the average daily population increase must be a positive value." and retrying. finally, do not accept a number less than 1 for the number of days they will multiply and use the message "the number of days must be at least 1."

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 08:00
What is the first step in creating a maintenance ?
Answers: 2
question
Computers and Technology, 23.06.2019 03:30
In vista and windows 7, the appearance and personalization option allows you to change the
Answers: 1
question
Computers and Technology, 23.06.2019 14:30
Select the correct answer. andy received a potentially infected email that was advertising products. andy is at risk of which type of security threat? a. spoofing b. sniffing c. spamming d. phishing e. typo-squatting
Answers: 2
question
Computers and Technology, 23.06.2019 15:00
In the blank libreoffice writer document, to start the process of entering a date field into a letter, click on the insert menu. edit menu. file menu. fields menu.
Answers: 3
You know the right answer?
5.11: population write a program that will predict the size of a population of organisms. the progr...
Questions
question
Mathematics, 21.10.2020 01:01
question
Mathematics, 21.10.2020 01:01
question
Physics, 21.10.2020 01:01
Questions on the website: 13722360