Ad
  • Custom User Avatar

    I totally redid my entire code, but ran into the same problem (different random test though).

    =========================
    Expected is <System.Collections.Generic.List1[System.Int32]> with 0 elements, actual is <System.Collections.Generic.List1[System.Int32]> with 142 elements
    Values differ at index [0]
    Extra: < 9997, 79, 9947... >

    I printed out the input and ran through the code manually and the return code should be good. It seems like the assert doesn't have the right (any) values in it.

  • Custom User Avatar

    Ah ha. Yep. That helps. Thanks.

  • Default User Avatar

    The easiest way to check the input is to print it at the top of your function. See if this works.

  • Custom User Avatar

    KenKamau,

    I am having some issues int he random tests, getting them to pass. All the crazy tests that I come up with pass, as do the "stock" tests. The random ones though, I get an error.
    I was hoping to get a list of the string input, so I can test review my code, or possibly see if there is a mistake in the expected result.

    In C#, the random tests are failing with this message:
    1838 but was 1842. Strings differ at index 83.
    Expected: "...eiopxtkrlzncdzsnlmlpizwldceumjqxyoacegavmuysvsaotmphnrmukt..."

    Obviously, I can tell you exactly what random test it is. Can you take a look at that one and confirm it is good? If so, can you send me the input?

    Thank you so much!

  • Custom User Avatar

    I am working in C# and all the listed testcases pass, but one of the random ones fails with this message:

    Expected is <System.Collections.Generic.List1[System.Int32]> with 0 elements, actual is <System.Collections.Generic.List1[System.Int32]> with 114 elements
    Values differ at index [0]
    Extra: < 9888, 14, 9719... >

    Other similar posts seem to point at some data needing to be corrected in the test cases?

    Otherwise I don't quite know what is happening. I have tried to mess up the known test cases to mimic this error and the only thing that does it is if I blank out the expected return data.

    Thanks!

  • Custom User Avatar

    As I get deeper and deeper into Katas, I am realizing how hard it is to code in Codewars.

    Finding values of variables as code is executing or when finished would be awesome.

    And yes, I know I could do all the coding over in a different environment, but that kind defeats the purpose a bit. Right?

    Also, this has nothing to do with this particular test, just something I am starting to notice.