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.
This is the type of out-of-the-box thinking I wish I had.
out of all of the solutions, this is the only one that i truly didn't expect
likely to use a machine instruction underneath; prefer this over the current top solution
thx
I didn't think about Math.abs() , its a great idea , i like your answer and your solution way.
Done
My kata requires a different approach to solve, which is not suitable for solving in the general version. My kata can be solved in O(1). So it's different
Could you hide this initial solution?
This kata was retired. It is important to make sure that tests are good before publishing a kata. You may create a new kata with the updated tests but I do not recommend it because there exists a general version of this task: https://www.codewars.com/kata/57b1f617b69bfc08cf00042a/python
Do not submit solutions which modify the testing framework.
Hello, monadius! I changed this kata and added tests for
BigInt
. Now the kata requires the use ofBigInt
. Thanks for this issue!No random tests. In order to create proper random tests, the input and output should be
BigInt
.i = leftBrackets[0]
is wrong because, again, the latest bracket is the last item of the array.I believe it should work now. Thanks for noticing that!
In the memory cells usage checks:
The first line is wrong as the latest bracket is currently on the last index. The second line is also wrong as when the code is something like this:
+[-[-]>+<]>.
this will result in 0 instead of 1 since the stateskip
from inner bracket still holds.Loading more items...