Ad
  • Custom User Avatar

    Thanks for the quick and thorough reply! I'm quite new to this (also not sure why this reply text area looks like the coding input window.. I'll figure it out sooner or later). Anyhow, yes I'm writing my answer in the solution window and not for the tests, and regarding the reference to 'A', I'm assuming A stands for each of the given test arrays that are plugged into the funtion, so After changing all my references to 'A' in my solution code (as opposed to 'array') that problem seems to be mitigated, but now when I do this:

    function findOdd(A) {
    for (let i = 0; i <= A.length; i++)
    //more code follows
    }

    'i' comes up as undefined. I don't recall ever needing to declare 'i' when iterating through an array.. I tend to get stuck on the most rudimentary issues so this could be one of those times. Thanks for any insight you may have into this(!)

  • Custom User Avatar

    The way the test module is set up is confusing. I'm writing a solution in the block for the given function with a parameter of 'A' and avoided changing anything that was already present that might disrupt the test. Without changing anything, and assuming 'A' to mean 'array', I'm writing what seems to be a workable solution, but then it doesn't recognize what 'A' even is and the test fails.. Has anyone else had this problem or know what I might be doing wrong?