Each bacterium divides by 2 every 3 minutes. Initially, there is 1 bacterium. How many there will be in n minutes.

Each bacterium divides by 2 every 3 minutes. Initially, there is 1 bacterium. How many there will be in n minutes. N is entered by the user. Build a program using a loop with a counter. (For counter: = start value to end value do)

program bacterya;
var i, x, n: integer;
begin
readln (n);
x: = 1;
for i: = 1 to n do
if (i mod 3 = 0) then x: = x * 2;
writeln (x); // x is the required number of bacteria
end.



One of the components of a person's success in our time is receiving modern high-quality education, mastering the knowledge, skills and abilities necessary for life in society. A person today needs to study almost all his life, mastering everything new and new, acquiring the necessary professional qualities.