Ad
  • Custom User Avatar

    Thank you for your reply.
    This way of task description is much more clear and readable. Now I see, that my understanding of task was wrong. Therefore my code is not correct.
    I think, that improving description like above mentioned will make it clear enough.

    P.S.
    And I want to thank you for your help and for creating Katas for this site. I like this sourse wery much.

  • Custom User Avatar

    I'm sorry for causing you trouble.
    “Each matrix will be represented by an array with a length of 4, which is the element order of the matrix from left to right and from top to bottom”
    Each array is a matrix, such as [a, b, c, d] is matrix

    a b
    c d
    

    Matrix can be rotated

    a b   90 degrees  c a  180 degrees  d c  270 degrees  b d
    c d  -----------> d b  -----------> b a  -----------> a c
    

    ”If matrix A can be obtained by rotating matrix B clockwise by 0, 90, 180 or 270 degrees, we think that A and B are the same matrix.“

    Can you tell me where you are confused and provide some suggestions for modification? Thank you

  • Custom User Avatar

    I am sorry, but the task description is very bad and blurry. I cant understand what exactly is expected to be done.
    I can only guess through the examples what my code is expected to do (return number/quantity of "unique" arrays in the matrix - arrays with the same numbers but ignoring its order, i presume). And I have no any variants of other meaning of task. Very crooked description.

    I tortured myself for a 3 days to create solution for this kata (considering my understanding of task). And, in the end, when I done it and checked in my web IDE (not here, not on this site), it was working excellent with all matrices from example and tests. But sample tests makes me sad - the mess with expected results. If my understanding of task is correct.
    FixedTests and SampleTests fails, RandomTests passed.

  • Custom User Avatar

    This code is too primitive. Is it written by a beginner/trainee? We need more head explodion code.

  • Custom User Avatar

    That input null handling tears me apart - we have to guess what kind of null treatment the designers wish to see. Obviously description fails.

  • Custom User Avatar

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

  • Custom User Avatar

    I don`t know, wether it is allowed to import new classes, but this way is the shortest one.

  • Custom User Avatar

    Nice, it`s really clear code.