diff --git a/Chapter 3/Exercise 3.4 b/Chapter 3/Exercise 3.4 new file mode 100644 index 0000000..fec4127 --- /dev/null +++ b/Chapter 3/Exercise 3.4 @@ -0,0 +1,15 @@ +const myCar = { + make: "Toyota", + model: "Camry", + tires: 4, + doors: 4, + color: "blue", + forSale: false +}; + +let propColor = "color"; +myCar[propColor] = "red"; +propColor = "forSale"; +myCar[propColor] = true; +console.log(myCar.make + " " + myCar.model); +console.log(myCar.forSale);