Tuesday, August 19, 2014

Previous Interview Question Next Interview Question
Home

which of the following indicates the error with the code below?

function myfunction()
{
var i=1,j=1;
do
i++;
while(j<=100)
alert(“The final value of i is:”);
alert(i);
return true;
}

a)      The function receives no arguments
b)      It is an infinite loop
c)       There are two alerts in a loop
d)      The function always returns true


Answer :  B

Previous Interview Question Next Interview Question
Home

0 comments :

Post a Comment