Answer: Object-Based
var a=5 , b=1 var obj = { a : 10 } with(obj) { alert(b) }
Answer: 1
Article and Schedule Quiz | Start Test! |
Code 1 : for(var num=10;num>=1;num--) { document.writeln(num); }Code 2 :
var num=10; while(num>=1) { document.writeln(num); num++; }
Answer: Code 1
Answer: block that combines multiple statements into a single compound statement
Answer: Ignores the statement
In the following switch syntax, the expression is compared with the case labels using which of the following operator(s)?
switch(expression) { statements }
Answer: ===
var count = 0; while (count < 10) { console.log(count); count++; }
Answer: The value of count from 0 to 9 is displayed in the console
Answer: If the object inherits enumerable properties
Int a=1; if(a>10) { document.write(10); } else { document.write(a); }
Answer: 1
var grade='B'; var result; switch(grade) { case 'A': { result+="10"; break; } case 'B':> { result+=" 9"; break; } case 'C': { result+=" 8"; break; } default: result+=" 0"; } document.write(result);
Answer: 9
var grade='A'; var result; switch(grade) { case 'A': result+="10"; case 'B': result+=" 9"; case 'C': result+=" 8"; default: result+=" 0"; } document.write(result);
Answer: 27
int a=4; int b=1; int c=0; If(a==b) document.write(a); else if(a==c) document.write(a); else document.write(c);
Answer: 0
var grade='E'; var result; switch(grade) { case 'A': result+="10"; case 'B': result+=" 9"; case 'C': result+=" 8"; default: result+=" 0"; } document.write(result);
Answer: 0