Solve our code challenge and win a TV

At the end of which day do we need to move the fish to new tanks?

Author
Solution Seeker
Publish date
· 2 min read

200 000 fish at a weight of 150 g each is placed in the tank at the start of day 1. Each day, the fish grows by a percentage of its own body weight. Unfortunately, some fish is also lost due to diseases and similar.

If we have a tank with a radii of 12 meters and a height of 8 meters. How many days can we keep the fish in the tank before the density becomes more than 75 kg/m3, and we need to re-distribute the fish?

Suggestion on how to solve

Solve the challenge using whatever method you like. Can even be solved using paper, though probably tedious and not recommended. Perhaps Excel is an alternative? Anyways, a Python implementation with utility functions is provided below. If familiar with Python, the challenge is probably most efficient to solve using your own Python installation (pandas package is the only external package needed) or Google Colab.

Files
Code

Python implementation with problem configuration and utility functions. Implement get_num_days_before_full() to solve the challenge

Link
Growth data

How many percent of it's own body weight a fish is expected to grow from one day to the next, given the weight [g] of the fish

Link
Mortality data

Of the fish that is lost, how many percent of these are lost before they reach a given weight [g]

Link

Note: we allow some slack in the answer (+- a couple of days)

Good luck! Submit your answer (number of days) to knut.v.eriksen@solutionseeker.no!