Ad
  • Custom User Avatar

    My array's values keeps getting reset right after being manipulated in the subtract function in one of the Attempt Tests, while it works just fine with the Sample Tests.

  • Custom User Avatar

    I am not sure what kind of "memory handling" or "memory optimization" you need to do, because it is definitely not the intention here. I checked a bunch of C# solutions, including mine old solution, and out of 10 solutions tested by me, all of them run in 3-3.5 seconds.

    We can use this as a starting point to make some conclusions :)

  • Custom User Avatar

    C# 12

    I don't know if I'm doing something very wierdly but the original test passes brilliantly but when trying to "attempt" it times out.

    Is the point of this to do memory handling or to make an interpreter? Because as it stands I've had to spend more time on learning memory optimization :/
    Unsure whether this is a CodeWars limitation and this Kata is simply too complex for CodeWars or if I'm just really dumb T_T

  • Custom User Avatar

    Will be good to mention in description, that random movement change(?) has to be distributed 50\50 (+-5%) between directions.

  • Custom User Avatar

    This kata would've been a lot better, and a bit tougher, if draws also counted games that had empty spaces but were unwinnable.

  • Custom User Avatar

    The possibility of a jagged matrix (i. e. lines of variable length) defeat the concept of "instructions scattered over a ‹two-dimensional plane›". It would only make sense to receive the input as a 2D matrix (i. e. a list of lists of fixed length).

  • Custom User Avatar

    not as simple as i thought

  • Custom User Avatar

    Thank you for your answer.
    Yes, it was my fault.
    I need to be attentive to details.

  • Custom User Avatar

    It's expected your answer to equal expected answer, so the expected value in the error message is 1 not -1. -1 is the value your function returned. Not a kata issue.

  • Custom User Avatar

    [[1,1,1],[0,2,2],[0,0,0]]: expected -1 to equal 1.

    The test expects -1, although the correct answer is 1.

  • Custom User Avatar

    Might just be me but I didn't think it was very clear that the input could have variable length rows & columns, and that the expected behaviour of "wrapping around" would be from e.g. index 8,10 to 7,6 when moving up if 7,6 is the furthest out index in that row. Could perhaps be made more explicit that this is the case.

  • Custom User Avatar

    lack of random testing

  • Custom User Avatar

    so once i removed the prints everything worked fine:P

  • Custom User Avatar

    This comment is hidden because it contains spoiler information about the solution

  • Custom User Avatar

    would it not also be a cat's game(no win con) before all tiles has been filled?
    eg: [[1, 2, 2], [2, 1, 1], [0, 0, 2]]

  • Loading more items...