list all properties of an object in JavaScript

JavaScript

🤖 Code Explanation

The code above creates an object called "obj" with three properties: name, age, and city. It then loops through each property in the object and prints out the property name and property value to the console.

Download SpellBox today