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.
Sorry you didn't like my response, sometimes reading the instructions again helps, now that I told you why those numbers can't be in the answer, because I did and only then suggested you read the instructions again. Again, you're not understanding what to do, you're looking at 658 as going from 6 to 8 and from 8 to 5 and you analize that pattern, right? And that's not what you should do, you saw 369, but that number can be 658 amongst others as I already explained. If you don't like my answer, just say "I don't get it", there is no shame in that, and I will try to explain it to you in another way, but please, next time, just be humble and read the instructions again now that you got new information and keep an open mind. After all, it's you who didn't get what to do and I am trying to help you.
Your response would have been more useful if you spent it on explaining the actual kata instead of just believing this was an opportunity for you to make yourself look superior.
How is "read the instructions again" helpful to anything if I've just posted that they weren't understood the first time?
From 369 you can reach 658 going always horizontally or vertically: from 3 to 6, 6 to 5 and 9 to 8. From 6, you can only reach 2 diagonally and the same happens when you try to go from 9 to 5. So no, 325 isn't valid. You're confused about what you should do, you start with a number, let's say 369, but you're not sure that's the number the robber entered, the 3 could also be a 2 or a 6, but not a 5, etc. Read the instructions again.
closing, as this would be a
suggestion
anyways, not anissue
. there are ways to properly free all of the memory in a standard-compliant way, and without using global variables.assertion messages for the PHP random tests are completely unhelpful:
Failed asserting that false is true
your solution is wrong, for example for
observed = "00001"
, it will return an array likearray(48) { "88818", "08818", "80818", "00818", ... }
--> the1
is treated as if it was in the 4th position, while it is in the 5th position in the input. though it is true that assertion messages are horrendous in PHP, i will raise an issue about that.Yes, returning
ACA
kills you by your own actions. A proper way to win here isACBA
. I added this to sample tests.yet another happy customer, what an easy job
Hello. I don't understand this test:
String: '\t# apples - apples apples\n=\n^'
Markers: [',', '!', '^', '.', '=', '?', "'", '#', '-']
'\t\n\n' should equal '\n\n'
Why do I need to remove the "\t"?
Ohhhh wait, that counts as whitespace, right? Ah nevermind
the error comes from your code: wrong index calculation, so you access invalid memory
should be:
(you forgot the + 1 for the nul terminator, and you got the pointer arithmetic wrong:
ptr + n
will addn * sizeof *ptr
toptr
, so you were going out-of-bounds ofpins
. The cast tochar *
needs to happen right away, in order to have byte-level memory access.)I do understand that, but 658 is one of the variations and that has the same pattern as 325. 6 and 8 are adjacent diagonally, but that is a valid solution
See the keypad again, 3 and 5 are adjacent, but diagonally.
Hello, just trying to understand the variations.
For this test example: "369": ["339","366","399","658","636","258","268","669","668","266","369","398","256","296","259","368","638","396","238","356","659","639","666","359","336","299","338","696","269","358","656","698","699","298","236","239"], how come 222 and 333 are not variations? Or 555? Or 325? But I see that 666 is there?
Quick question:
Let's take this one for example: act(2, [[8, 2], [8, 2], [8, 1]]);
If I get to the last enemy and kill them with A, but using A depletes my health points to zero, did I win or lose?
done
Loading more items...