Question
Write a program using C# to solve the following problem: Lieutenant Uhura is visiting the space station K7 from the USS Enterprise. While there, she
Write a program using C# to solve the following problem: Lieutenant Uhura is visiting the space station K7 from the USS Enterprise. While there, she meets a man named Cyrano Jones who sells her a pet: a ball of fur called a Tribble. Doctor McCoy later examines the Tribble and makes the following observations: Tribbles are born pregnant and reproduce asexually. Tribbles never die except by poisoning. After twelve hours of lifeand every twelve hours thereaftera Tribble will give birth to a litter of ten baby Tribbles. Assuming the Tribble that Lieutenant Uhura purchased was a newborn and it was the only one brought back from the space station, after three Earth days, how many Tribbles will there be on the Enterprise? After four days? Your program should be able to predict the number of Tribbles after any length of time (in hours).
Examples: (tribbles 0) ==> 0 # the original Tribble
(tribbles 12) ==> 11 # the original Tribble and its 10 offspring
(tribbles 24) ==> 121
(tribbles 36) ==> 1331
(tribbles 48) ==> 14641
(tribbles 60) ==> 161051
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