Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

A biologist determines that the approximate number, number, of bacteria present

ID: 3546946 • Letter: A

Question

A biologist determines that the approximate number, number, of bacteria present in a culture after Time (in days) is given by the following formula: Number = BacteriaPresent * 2^(Time/10) Where BacteriaPresent is the number present at the beginning of the observation period. Let the user input BacteriaPresent, the number of bacteria present at the beginning. Then compute the number of bacteria in the culture after each day for the first 10 days. Do this in a loop so the user can see the results in a table. The output table should have headings for Day and Number of Bacteria Present (on that day)

Explanation / Answer

#include <stdio.h>

#include <math.h>


main()

{

int tim,i;

unsigned long n,pnum,innum;

printf("enter initial bactera number ");

scanf("%lu",&innum);

printf("enter time in days ");

scanf("%d",&tim);

printf("%d",tim);

for(i=10;i<tim;i=i+10)

{

n=innum*pow(2,i);

printf("after %d days bactera no =%lu ",i,n);

}

pnum=innum*pow(2,tim);

printf("after %d days bactera no =%lu ",tim,pnum);

}


Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
Chat Now And Get Quote