# 12/15 [resolved] Decisions Decisions

Im confused about the If and else statement in the example... What does the 10<3 pertain to... Is it the numbers in the arrays? Why choose 10 and 3? Why can't it be

If you could explain the reason behind those random numbers and what they pertain to/ why those numbers... that would greatly be appreciated. Thanks

Hi Dean,

Here is how if/else statements work:

``````if (this is true) {
do this thing;
} else {
do this other thing;
}
``````

In the example in the exercise, the (10 < 3) is nothing special, except for the fact that it is false. that will cause your if/else statement to "do this other thing". If you want it to "do this thing" then you will need to make sure that what is in the ( ) is true.

There are endless expressions that you could put in the ( ) that will be true. Here are a few examples:

``````1 === 1
1 <= 20000
1 != 42
"Dean".length === 4
true
!false
``````

Have you been through the JavaScript Track exercise where they explain Comparison Operators yet?

That does not help

##### 1 Comment

Judy over 3 years ago