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.
My solution is an array wich first element is the highest value of the array and the second element is the second highest value of the array.
Sorry, I dont understand what you mean with the word mutate.
I dont understand why for the input
[52359, 86937, 63480, 43951, 26522, 14543, 97719, 75202, 17498, 76899, 38367, 6940, 52720, 71337, 57809, 98606, 827, 52453, 65904, 36280, 77386, 4433, 55644, 20134, 95284, 43207, 58752, 19164, 5214, 80570, 66083, 42417, 36423, 95450, 79775, 61809, 61856, 79566, 30627, 68128, 13701, 97031, 60769, 33254, 27015, 41398]
I received the following error message
[98606, 97719] should equal [97719, 97031]
The two highest values are 98606 and 97719 and it's easy to check that it's true.
I have used python. Thanks!
I really enjoyed this Kata! More Kata of security please!
It's not very difficult but maybe it would be a 7 kyu. Nice kata, I have learned some features of python that I didn't know.
Very funny Kata but it's very easy to be a 4 kyu. I think that you would use more difficult tests (especially to prove the efficiency of the program) or downgrade the Kata to 6 kyu.
I pass around 45 tests but then I get Execution Time Out, can anyone give me a suggestion? I think that I am near of the efficient solution because the total of tests is 55 but I dont know what else I can do to improve my code.
Thanks!
Ok, so I have a very long way to walk yet, thank you!
Sorry I am new with Python and I didn`t know the parameter flush. I have used it and I pass about 20 tests before the Execution Timed Out. I mean, in my case the problem is not a particular test but the number of tests.
I don't use recursion. In fact I use a very different method to solve the problem. How can I see the test wich produce the Execution Timed Out? If I could see the test maybe I could solve the problem...
Python
I have no idea why I get a Execution Timed Out. When I do tests on my own I get the correct answer. I test small numbers and big numbers like 333333434131414141434141343141441365678 on my own and I get the correct answer in less than a second so I dont understand why I can't pass not even the first test of the kata. What kind of tests do the kata?
It is understood, thank you JorgeVS. I will try to be less specific in the suggestion the next time.
Cheers!
Why is it spoiler? Only I put an example that represents the situation wich may is causing problems to the users that haven't solved the problem yet.
The question is serious, I am new at this web and I don't know why it is spoiler. I didn't show code or something similar.
Sorry for the inconveniences.
This comment is hidden because it contains spoiler information about the solution
Loading more items...