Adding and removing properties
π Scenario: You are managing a simple contact list where each contact is an object with properties like name and phone number.
π― Goal: You will create a contact object, add a new property to it, remove an existing property, and then display the final contact details.
π What You'll Learn
Create an object called
contact with properties name and phone.Add a new property called
email to the contact object.Remove the
phone property from the contact object.Print the final
contact object.π‘ Why This Matters
π Real World
Managing contact information in apps or websites often requires adding or removing details dynamically.
πΌ Career
Understanding how to manipulate object properties is essential for frontend and backend developers working with user data.
Progress0 / 4 steps