JavaScript - Comparisons with the Logical And Operator

Please help, I can’t figure out what am I doing wrong. Also, when I press “Run Tests” - it doesn’t do anything, and doesn’t show me which ones I have to correct.

https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/basic-javascript/comparisons-with-the-logical-and-operator

function testLogicalAnd(val) {
  // Only change code below this line

  if (val <=50 && val >=25) {
   
      return "Yes";
    }
  }

  // Only change code above this line
  return "No";
}

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

First, please post your code so we can see it and see if that is a problem.

Even if it fails, “something” should happen. Foe example, you should see all the results of the tests down below on the left.

1 Like

That’s the thing usually “something” happens, it shows me which result I completed and which not, but in this case it just doesn’t do anything. I tried refreshing the page, resetting the code and writing it again.

@ella I’ve edited your post for readability. When you enter a code block into the forum, precede it with a line of three backticks and follow it with a line of three backticks to make easier to read. See this post to find the backtick on your keyboard. The “preformatted text” tool in the editor (</>) will also add backticks around text.

markdown_Forums

1 Like

Review your code carefully. You have an extra } in your code which is not letting the code run.

2 Likes