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.
I understand how this works already.
I was just commenting because i found this solution to be quiet funny :).
Why? Just why... I love it.
Seems like the issue has been raised.
I was just taking into account that not everything was covered. For example the letter "o" is not covered on this kata.
This should have been covered by the random tests and if not then atleast the basic tests.
This comment is hidden because it contains spoiler information about the solution
There is no test that contains only two items after viewing it, even if there was it would mean 216 people wouldn't be able to complete the task.
You must have edited one of the sample tests :).
216 people have completed this kata in C. This is clearly not an issue with the kata but more an issue with your code.
If you keep trying you should be able to figure it out :).
If you look at the example, the place where it says (YOU ARE HERE AT THE FRONT OF THE QUEUE) is not where the array starts when given to you.
(THE ARRAY STARTS HERE) [sheep, sheep, sheep, sheep, sheep, wolf, sheep, sheep] (YOU ARE HERE AT THE FRONT OF THE QUEUE)
So now when you are doing indexOf("wolf") in this instance you will get 5. Then you are doing -- which will give you the index of 4.
This will give you the wrong answer but a personal recommendation is to reverse the array when working with it.
Hope this helped :)!
Saying that 471 people have completed this question in JavaScript it is very likely your code is incorrect.
Also since there are random tests on this kata you will find that the passed/failed amount will vary.
I think that suggestion maybe for a different website...
And you cheated and passed and basically got nothing from it :).
More comments of course would make this better. You know, a few talking about what each bracket does...
I'm just going to grab response that Chrono79 wrote which seems to relate.
Second argument (optional)
See the sample test: titleCase('the quick brown fox') there is no second argument there
This kata seem's just like marmite, you either love it or you hate it...
That is something for you to figure out :)
Loading more items...