0

Can someone break this down and help me understand?

In a JS challenge with my fiance we both got this wrong. The question was to determine the output of this code: var a = 10,b = 20,c = 30; if (c > b > a) { console.log('1'); } else { console.log('2'); } We answered 1 and the answer was 2. Can someone help me to understand why? Especially if it's something really easy we're missing.

30th Jul 2021, 8:17 PM
Starii
Starii - avatar
1 Antwort
+ 1
Thanks for breaking it down, that helped.
30th Jul 2021, 9:02 PM
Starii
Starii - avatar