Submitted by KMacKenzie on Wed, 03/02/2011 - 16:35
Re-implement the following rules from your previous exercise using this new framework. Choose your value for n, m, and k carefully so that your simulation is stable (will not get too slow or have all the creatures disappear).
Make the fox die (disappear) if it has not eaten anything after 50 turns.
When a tux is eaten by a fox, n% of the time, create a new fox in place of the dead tux.
When a tux is close to another tux, m% of the time, a new tux is born.
When k or more tuxes are close in proximity, they all get overcrowded and die.
Make it so that the user can choose the values for n, m, and k.