Source code
Revision control
Copy as Markdown
Other Tools
var a = ['p', 'q', 'r', 's', 't'];
var o = {p:1, q:2, r:3, s:4, t:5};
for (var i in o)
delete o[i];
for (var i of a)
assertEq(o.hasOwnProperty(i), false);
var a = ['p', 'q', 'r', 's', 't'];
var o = {p:1, q:2, r:3, s:4, t:5};
for (var i in o)
delete o[i];
for (var i of a)
assertEq(o.hasOwnProperty(i), false);