Make the probability of a rabbit dying increase with age, ie extra 5% per term

From TRCCompSci - AQA Computer Science
Revision as of 15:58, 13 February 2017 by Admin (talk | contribs) (Created page with "The skeleton program has a method to get the reproduction rate but nothing to set it. The variable itself is also private, so a method is required: <syntaxhighlight lang="csha...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

The skeleton program has a method to get the reproduction rate but nothing to set it. The variable itself is also private, so a method is required:

1     public void SetReproductionRate(double value)
2     {
3         ReproductionRate = value;
4     }