Basic JavaScript: Comparison with the Inequality Operator

Tell us what’s happening:

Basic JavaScript: Comparison with the Inequality Operator

even using the hint and revealing what the code is, then pasting the solution, it still will not let me advance to the next task. I have also changed the function name to compareEquality as it seems to reccomend once the tests have been run and that does not work either. it asks to also use the === operater in this section and still i have no luck after adding that, thanks :slight_smile:

Your code so far

    // Setup
function testNotEqual(val) {
  if (val != 99) { // Change this line
    return "Not Equal";
  }
  return "Equal";
}

// Change this value to test
testNotEqual(10);

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 6.3; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/77.0.3865.90 Safari/537.36.

Challenge: Comparison with the Inequality Operator

Link to the challenge:
https://www.freecodecamp.org/learn/javascript-algorithms-and-data-structures/basic-javascript/comparison-with-the-inequality-operator

@osulmyl Your code should pass with no problems. What browser are you using? Which tests are you failing?

1 Like

Hey Randell, thanks for the quick response! I ended up just going back to the page with the JS tasks listed on it, opened up the problem again and it submitted without issue, absolutely no idea why it was stopping me from doing it before :s
I stuck with the same browser and to my knowledge changed nothing so really unsure what the problem was :sweat_smile:

1 Like