JavaScript Treehouse Club - MASH MASH - JavaScript Important Stuff - Part 3

Emanuel Rios
Emanuel Rios
6,966 Points

what is the meaning of ll in JavaScript?

I'm doing the quiz about the game program called "MASH" created by JOY from Treehouse and i do not know what ll exactly means, can somebody help me? Thank YOU!

2 Answers

Jonathan Grieve
MOD
Jonathan Grieve
Treehouse Moderator 82,205 Points

I think you're referring to the || operator in JavaScript which translates as OR in JavaScript.

What this does is expands the possibilities of condition statements so that you can test for more than one value. So you're testing whether the value of an expression is true, or false.

If you're using OR in condition statements only one of the values you are testing as to be true for the given code block to run.

If you're using && or AND in your condition statements, all the conditions you test have to be true for the code block to run.

Emanuel Rios
Emanuel Rios
6,966 Points

Perfect! Thanks for your help Grieve