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.
indeed, the PHP, Haskell and C# version have undue (since this kata is about how to define mutually recursive functions, not how to optimize the sequence generation) performance tests
there is an open issue regarding this
For those interested in understanding: The 10 expected is the position in the array, not the integer value of a peak
Since upon every iteration which satisifes a specific condition, the string
s
is updated, resulting in length change. This happens cocurrently with the increment ofi
in which the position assessed by it in the string is not correct anymore. (i.e, not following the original positioning of each characters in the string)Example:
For case #3 above, the original behaviour should be
s[i] = 'c'
Your solution is not correct (read the description, you are not doing what is requested). The C# translation is fine.
This is due to the lack of random tests, already pointed out.
Which language?
I just checked the C# version of the kata and it seems to work OK for me.
Do you mutate the input list by any chance?
If there's a translation for it in a language, it's possible in that language.
Same, dude sounds like he's a fan since he knows about DeathCubeK
Make sure you're not mutating the input array and also, there are more than 3 peaks there, so your answer is wrong.
First step is noting that a factorial is defined as a product of some set of numbers. Think how you could find all prime factors of a number which itself is a result of multiplication of other numbers.
Thanks
https://docs.codewars.com/training/troubleshooting#post-discourse
Try testing it with something like [2, 2, 3] and [4, 9, 9]. Your code would return true, when it shouldn't.
Loading more items...