<!DOCTYPE html>
<html>
<body>
<table>
<tbody id="tbody"></tbody>
</table>
<script>
var obj = { "key": "apple", "value": 1.90};
var a= Object.keys(obj).length;
document.write(a);
</script>
</body>
</html>
output: 2
<html>
<body>
<table>
<tbody id="tbody"></tbody>
</table>
<script>
var obj = { "key": "apple", "value": 1.90};
var a= Object.keys(obj).length;
document.write(a);
</script>
</body>
</html>
output: 2
No comments:
Post a Comment