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'd love to have the tasks of the same difficulty on my job.
I like simple explanation what to do but only came up with loop solution.
Haskell translation
Diamonds are forever
you are hardcoding the amount of memory, even though the amount is dynamic and depends on the input. you do not allocate enough memory for large
n
and write out of bounds, hence the crashtoo late now with more than 10 languages and 37,000 completions
added
No random tests in Java
strpos
works correctly. You have to ask yourself whatstrpos
will evaluate to when the character in question isa
, and what that means in anif
condition.This comment is hidden because it contains spoiler information about the solution
thanks!
Well, it looks like you never submitted your solution, this kata is not listed in the "kata" tab on your profile. You might want to go into the trainer and hit "attempt" and submit it.
Oh, I fixed it with my teacher. I forgot to return the variable and instead printed it.
Your code passes the tests for me. Do you get an error or anything?
when I test the code it comes up with the right answers but still marks it incorrect :(
Loading more items...