comparison check
JavaScript
var a ;
if ( a != undefined || a!= null)
{
console.log("value there");
}
else { console.log("no value");}
/* above comparison can be reduced to below */
if(a)
{
console.log("value a there");
}
else { console.log("no a value");}
/**** ==== better than == check ******/
var a = 10
if ( a == "10" ) console.log("string value check");
if ( a !== "10") console.log("better check");