15 computers are smart,


Is there a bug here?

since the "if" condition is false, the "else" console.log is supposed to run RIGHT?

look at my results,


Your condition is a string, it's text, a series of characters. It's not code, it doesn't do anything, doesn't compare anything.


but as it stand it's false right, I would say equating/comparing 32 to 23.


No its a string so its just reading it like a sentence you would need to have entered that statement without the " " and it would have return the 2nd console.log statement.

if ( 32 === 23) would make the 2nd console.log print


Wow! interesting, thank you very much guys, but then what does this say about (conditions)? they have to be "doing, acting, comparing" in order for them to be true/false booleans.
In this case I messed up with "quotations", which becomes my coding problem. Thank you very much once again!


That they don't strictly have to be boolean


or they strictly have to be boolean, depending on the question? I have learnt something very valuable today. much appreciated again!


The big thing to take with you is that "" create strings and that those are not code.

Sometimes it can make sense to use other values than true/false as a condition, but it's usually better to just say what the intention is, write them as comparisons anyway.

An example, not good code, more of how it can be used:

var i = 6;
while (--i) {

This is preferred, because everyone knows what it is almost without reading it. It's a common pattern.

for (var i = 0; i < 6; ++i) {


Here is an explanation of truthy or falsey. There might be better explanations out there but this one came up first in a Google search.

All strings, except "" evaluate to true. That is what you are seeing there.