Consider following code snippet:

var a = '' || 0 || 2 || true || false;
var b = 3 && true && false && null;
console.log (a,b);
What will be printed to the console?
Explanation
Get an explanation when it's available:

|| : ''-false;0-false;2-true;DONE! && : 3-true;true-true;false-false;DONE!

2016 Dec 14, 8:17:58 PM

Follow CodeGalaxy

Mobile Beta

Get it on Google Play
Send Feedback