Advertisement
Guest User

Untitled

a guest
Dec 16th, 2019
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1.  
  2.  
  3. #include <iostream>
  4.  
  5. int kletka(int ameba, int time)
  6. {
  7. if (time < 24)
  8. {
  9. ameba *= 2;
  10. time += 3;
  11. printf_s("Через %d ч. будет %d клеток\n", time, ameba);
  12. kletka(ameba, time);
  13. }
  14. else
  15. return 0;
  16. }
  17. int main()
  18. {
  19. system("chcp 1251");
  20. int ameba = 1;
  21. int time = 0;
  22. kletka(ameba,time);
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement