var x;
try{
x in window;
alert('true');
}catch(e){
alert('false');
}
try{
y in window;
alert('true');
}catch(e){
alert('false');
}
try{
x in window;
alert('true');
}catch(e){
alert('false');
}
try{
y in window;
alert('true');
}catch(e){
alert('false');
}
var a;
function varof(s)
{
try {
eval(s);
return true;
} catch(e){
return false;
}
}
alert(varof("a"));
alert(varof("b"));
var b;
alert("b" in window)