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.
Was surprised my bruteforce first try didn't timeout! Would have been interesting to try with huge arrays ... Nice kata anyway!
Nice cata! You would not believe the time a spent to realize that having no parentheses was a valid option
First of all i'm sorry for my excessive behavior towards you! I guess i must have been having a rough day... (not that it's any excuse)
Regarding the issue at hand, I was attempting it in C#!
As several people pointed out the basic tests are plain wrong! I seriously question how this mess of a kata managed to get 91% approval from the community! Wasted serious amount of time on a author mistake . . .
Edit: After looking at the responses regarding issues in other katas from this author it seems he is truly incompetent since he refuses to solve the clear issues. It seems his idea of contribution to this website is to force the users to waste time on trivial bullshit!
This comment is hidden because it contains spoiler information about the solution
SQL newbie here! Despite passing the test case when trying to submit it fails despite the table that showed up being correct! I'm not sure whats going on and would like some hints about whats going on! My code is in the replies.
I never thought that calculus class would be useful...
assuming it's the same as in java you have to give the perimeter of n+1 squares. As such n==1 and n==2 won't have the same result.Furthermore you should reread the problem as you are also returning the wrong values for these cases...
I solved it in java and the main struggle was to figure out how to work with BigInteger. I made a first draft fully expecting it to fail due to timeout since i thought the numbers tested would be huge but it doesn't seem to be the case. Maybe long or some more standard type would be better suited? Anyway pretty good kata which,if nothing else, thought me about BigInteger! :D
Wording aside this is a great kata!As some have said this is way easier on some languages (such as python) and harder than 5 kyu in other (such as java which i'm attempting atm).
As people have pointed out there seem to be some problem with the java test cases! The random tests sometimes complete other times it doesnt due to some sort of aproximation issue. Furthermore one of the basic tests is too long leading to an out of memory error. . .
Edit: Regarding the issue with the basic tests after looking through some comments i figured out that n can be lower than the size of signature. After accounting for that I managed to solve it!
Looks way simpler than it really is. Really enjoyed this one despite being stuck for over an hour as a result of speeding through the details.
Found the issue. If the user was already rank 8 i was skipping the error handling.
Which error am i supposed to raise when inc_progress is given an invalid argument? Solving in Python