-
Consider the following code snippet
function output(n)
{
for(var v in n)
console.log(v + ": " + n[v] + "\n");
}
What will the above code snippet result ?
-
- prints only one property
- Prints the contents of each property of n
- prints the address of elements
- Returns undefined
- None of these
Correct Option: D
The above code snippet returns undefined.