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.
Please don't post solutions in Discourse.
This comment is hidden because it contains spoiler information about the solution
Exactly what I thought! lol.
'Looks like you've solved it'
This comment is hidden because it contains spoiler information about the solution
Your code is too slow. The final tests use some really big values for n.
I have removed the unnecessary whitespace when I was calculating.
I can give you advice is: As a stingy person,
var
is not needed ;-)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 think the test code is fine, I just submitted my solution again and it passed all of the tests. It's hard to tell where the syntax error is with only that error message. If you reply with your solution code with a Spoiler tag, I could take a look at it.
I use PyCharm and when there is a
SyntaxError
it underlines the area with red and puts a red line in the scrollbar on the right hand side of the editor (before you execute the code). It makes it easy to see where a potential mistake is.http://xkr.us/articles/javascript/unary-add/
I'm glad I can help you.
Thanks for your feedback ;-)
Hi! welcome to Codewars ;)
on the description, it is said that the function "can be called infinitely"
means that the return of your function should be callable a.k.a returning another function.
hope this helps.
Thanks for your kind post! You could have posted - when you are not perfectly sure of your code - as a question. Don't worry, no harm made:-) I am happy you got it!
Please which language?
You can see that 1117 Codewarriors passed the kata so one can be sure there are no errors in the tests.
Moreover please don't post as an issue before knowing that your code is correct. Issues are rather for problems in the kata than for problems in your code.
Don't need a screenshot, simply post the failing tests within two series of three backticks. Google "markdown" if you don't know how to do.