Ad
  • Custom User Avatar

    It's not mentioned in the description or anti-cheat fail message that any import at the outmost scope will trigger the anti-cheat test. It definitely should be mentioned (and should also mention that importing inside inner scope, e.g inside the function, is fine).

  • Default User Avatar

    How can I know how to improve code performance in order to dont get timeout (python)? Can someone help?

  • Custom User Avatar

    Consider what you want in terms of performance. Then test for correct Big-O time complexity instead of having compliant solutions take 11 seconds. Succeeding should take on the order of 1 second for compliant solutions, while uncompliant solutions should time out consistently.

    Please read the chapter on performance testing in the documentation carefully. Get help if you have problems understanding or implementing performance requirements. Beware of requiring micro-optimisations!

    According to the below issue, Python has this problem; JS has it as well. The example solution takes 6 seconds, both submitted solutions take 11 second. This is indicative of too many not large enough tests, though there is something to be said for not too few tests.

  • Custom User Avatar

    Python tests are not well balanced - my solution passes them in 9.5-10 sec but still times out once in 10 or so attempts.

    Also, why on earth does testing take so much time? In general case, a valid solution shouldn't almost time out just to pass the tests, even if there're performance requirements.

  • Default User Avatar

    I am getting the error: "living_room should be the only name in the global scope, and it should not have a state," but I haven't added any additional variables to the code, inside or outside of living_room.
    Can someone give me a hint as to what this might mean?

  • Custom User Avatar

    Why are we supposed to implement a curried function? Other than "I want it to be so" of course.

  • Custom User Avatar

    There are at least three other Roman numeral encoders. Extending existing logic by extending the digits without changing the logic itself, and passing the digits as an argument instead of using the classic ( literally :P ) predefined I, V, X, L, C, D, M, does not really add novelty. It's just more of the same.

    Duplicate.