Examveda
Examveda

Consider the following code snippet
function printprops(o) 
{
  for(var p in o)
  console.log(p + ": " + o[p] + "n");
}
What will the above code snippet result ?

A. Prints the contents of each property of o

B. Returns undefined

C. All of the mentioned

D. None of the mentioned

Answer: Option B

Solution(By Examveda Team)

The above code snippet returns undefined.

This Question Belongs to Javascript >> Array And Function

Join The Discussion

Related Questions on Array and Function