top of page

Bacterial Multiplication Rate

One bacterium divides to make two bacteria every 20 minutes. Starting with one bacterium, how many bacteria would you have after 60 min, 120 min, 240 min? Hot long would it take to get to 1 million bacteria??!!! Create an interactive program to model the multiplication rate of bacteria.

BittyHack Programing Challenge
Bacterial Multiplication Menu.png

Step 1 - Enter the template.

Look at the code that is there to help you. This code will make your bacterium appear in the same spot every time you press the green flag as your explore and discover how to put your code together.

Kepp Track of Bactericorn.png

Step 2 - "Clone" Your Bacteria.

Make your bacteria multiply when you press the space bar. One bacterium should make two. Then two should make four. Then those four should make eight.

Hooray! You Did It!

You made a model that illustrates the multiplication rate of bacteria. Every time you press the space bar, that represents a 20 minute time step.

Need Help_ Heres a Tip.png

Enhancement 1 - Keep Track of Time.

Create variable to keep track of time and then make the time counter change by 20 minutes every time you press the space bar. You can see if you did this right by looking at the time display when you hit the space bar. This is what you are trying to do; 

Time.png
Time 40.png
Time 80.png
Time 60.png

This is what you see initially:

(Hit the space bar)

(Hit the space bar)

(Hit the space bar)

(Hit the space bar)

Time 0.png
Time 0.png
Need Help_ Heres a Tip.png

You must also program "Time" to set to 0 when you push the start flag. 

Enhancement 2 - Count Your Bacteria.

Create variable to keep track of how many bacteria you have. Then multiplication block to change the number of bacteria every time you press the space bar. To do this create a variable called "Bacteria Count"

The bacteria count should increase like this when you hit the space bar;

1, 2, 4, 8, 16, ...

You must also program "Bacteria Count" to set to 0 when you push the start flag. 

Need Help_ Heres a Tip.png

Enhancement 3 -

Animate Your Bacteria.

Now make your app more interesting.

1. Make your bacteria change costume

2. Give your bacteria movement

3. Make them say things

Now you are done. Can you use your app to answer the following questions?

- How many minutes does it take to fill your whole screen with bacteria?

 

- How many minutes does it take to get a million bacteria?

- How many minutes does it take to jump from a million bacteria to a billion bacteria? The answer is very surprising!

Need Help_ Heres a Tip.png
Bacteria4.png

Do you still need help?  Click me to reveal the finished project.

bottom of page