Q. Consider the following code snippet.
What does this code result?
Code:
What does this code result?
function printArr(n)
{
var len = n.length, p = 2;
if (len == 2)
console.log("Nothing is in Array");
else
{
do
{
console.log(n[p]);
} while (++p < len);
}
}
β
Correct Answer: (B)
Prints the numbers in the array in order