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.
bro make your kata a bit easier
I think you mean "wh4t"
what
hard for me :(
In your last example
{1,2,3,4,5,6}
the answer is-1
because you can not select one position and have both sides equal the same number. In your answer ({1,2,3} = {6} => 1
) you have chosen to select 2 positions to work around rather than one: position 3 and 4. I have no idea where you got the number 1 for that answer, but the answer is -1 because you can not select one position where both sides are equal.As for your original question: (
{2824, 1774, -1490, -9084, -9696, 23094} => 1 how is that happen?
), let's take a look at the answer.You have
{2824, 1774, -1490, -9084, -9696, 23094}
.You have to select a position where both sides are equal.
Let's start with position 0
At position 0 the number is
2824
, to the left of position 0 is{}
(we count this as a 0), and to the right of it is{1774, -1490, -9084, -9696, 23094}
(sum of these = 4598)We compare the sums:
0 != 4598
so this is not our answer.Next is position 1
At position 1 we have
1774
, to the left of position is{2824}
(sum = 2824), and to the right of position 1 is{-1490, -9084, -9696, 23094}
(sum = 2824)We compare the sums:
2824 == 2824
so this IS our answer!We return position 1 as our correct answer.
If you have any other difficulties understanding this problem let me know and I'll see if I can set you straight.
Im having a difficulty in the instruction
{2824, 1774, -1490, -9084, -9696, 23094} => 1
how is that happen?
you say {1,100,50,-51,1,1} => 1
because {1} = {50,-51,1,1} => 1
AND
{1,2,3,4,3,2,1} => 3
because {1,2,3} = {3,2,1} => 3
So why {1,2,3,4,5,6} => -1?
{1,2,3} = {6} => 1 right?