Đàm Ngọc Lan
New member
What will be the output of the following JavaScript code?
A. Prints the contents of each property of o
B. Returns undefined
C. Prints only one property
D. Prints the address of elements
Code:
function printprops(o)
{
for(var p in o)
console.log(p + ": " + o[p] + "\n");
}
B. Returns undefined
C. Prints only one property
D. Prints the address of elements