Ad
  • Custom User Avatar

    There is no issue; functions in tests are inaccessible to the user in JavaScript.

  • Custom User Avatar

    Something is wrong here..I get the right answer when I print the value before returning, but when the value is returned the return value is not same as the print statement just before that! Btw, the code is in python.
    print(distance) - this print right value
    return(distance) - the value returned is wrong here!

  • Custom User Avatar

    I'm not insulted, I completely acknowledge that I feel like I'm in over my head a little. Is there any way this issue can be resoved?

  • Custom User Avatar

    It is.

    And something has been fixed.

  • Custom User Avatar

    the validation function can still be accessed by the user

    Not in JavaScript it can't; tests are already in a closure. Preloaded can be accessed.

    I don't mean to insult, but it looks like both of you don't know what you are talking about.

    Usually, we call the 'validation function' the 'reference solution'. That'd be furthestDistanceTest in your tests. The original issue has been resolved BTW.

  • Custom User Avatar

    I believe this issue is resolved now.

  • Custom User Avatar

    Hi, what is the 'validater definition'?

  • Custom User Avatar

    allow contributors is ticked.

  • Custom User Avatar

    Uses the same name for both the user function and validation function. Also, even if you change the name, the validation function can still be accessed by the user. It needs to be hidden somehow. Wrap the testing logic in a function of its own and move the validater definition inside that function.

  • Custom User Avatar

    ( JS, possibly others )

    Submit tests are comparing the user solution against itself.

  • Custom User Avatar

    That's rightfully an issue. The tests are comparing the user solution against itself .. :O

    And allow contributors is off, so only OP can fix this.

  • Custom User Avatar

    I noticed I just passed the test using console.log
    I think there is something to be fixed.
    Thanks