Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
The description is confusing.
It is not clear what is the expected result and I suspect most of people will spend most of time trying to figure out not how to implement it, but what should they do.
I did it by trial and error.
There should be annotation like:
Return the number of ADULT PAIRS of rabbits at the BEGINNING of the mth month.
This comment is hidden because it contains spoiler information about the solution
If you try to assign new object or value to the variable with final keyword, the code will not compile.
You should use it, if you specifically do not want any other programmist (or yourself) to change the value, because some of your code depends on it. In example:
final double PI = 3.1415;
// PI = 10.0; this line would not compile
In this kata:
x = "my custom solution"; // would not compile
This comment is hidden because it contains spoiler information about the solution
This comment is hidden because it contains spoiler information about the solution
I wish I won't ever inherit such code to maintain :)
Well I don't like the naming convention here. What does it tell us that search() method returns true?
Imagine you've asked police to search for your stolen car and they return to you with "yes". :v
I'd suggest 'exists' or make 'search' function return a value;