question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Instruction or objective is wrong in the question

See original GitHub issue

Challenge Comparisons with the Logical Or Operator has an issue. User Agent is: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/50.0.2661.86 Safari/537.36. Please describe how to reproduce this issue, and include links to screenshots if possible.

My code:


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

  if (val>=10 || val<=20) {
    return "Outside";
  }

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

// Change this value to test
testLogicalOr(15);

Combine the two if statements into one statement which returns “Outside” if val is not between 10 and 20, inclusive. Otherwise, return “Inside”.

Either instruction is wrong here or objective is wrong How can you you check between condition with || operator? I think there is some bug.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
milpoolcommented, May 13, 2016

since I have changed all of them I cant give you a screenshot with the error.

1reaction
raisedadeadcommented, May 11, 2016

@swapy Thanks for the issue, but this is not a bug with the challenge. The || can be used to check the between condition.

I am tempted to give you a hint if (val>=10 || val<=20) translate this into pure English and maybe you will get what’s wrong

If val is greater than/equal to 10 OR if valis lesser than/equal to 20

Something similar like union of sets?

Please consult the JavaScript Chat Room for any assistance to Coding.

Happy coding!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Objective or Subjective? Those are the Questions
But a common worry is that objective tests cannot assess learning beyond basic comprehension. However, questions that are constructed ...
Read more >
7 Mistakes to Avoid When Writing Multiple-Choice Questions
Solution: Check for grammatical consistency. When using “a” or “an” make sure there is agreement with the wording of the options. Don't ask...
Read more >
Avoid Common Mistakes When Writing Learning Objectives
However, a common mistake is to write the objective and focus on what the teacher is planning to do in the lesson.
Read more >
Writing Good Multiple Choice Test Questions
1. All alternatives should be plausible. The function of the incorrect alternatives is to serve as distractors,which should be selected by students who...
Read more >
14 RULES FOR WRITING MULTIPLE-CHOICE QUESTIONS
14 RULES FOR WRITING MULTIPLE-CHOICE QUESTIONS. 1. Use Plausible Distractors (wrong-response options). • Only list plausible distractors, even if the number ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found