You will write functions for the growth of a tumour that grows from one cell by doubling.
The idea. After doublings there are cells. A billion cells weigh about a gram.
Your tasks.
cells. It gives the number of cells after some doublings.doublings_for. It gives the smallest number of doublings after which there are at least target cells.years_for. It gives the years taken by some doublings, if one doubling takes days days. Round it to one decimal place. Use 365 days for a year.Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…