1. 動态添加對象的屬性和方法
2. 一次性建立對象
3. 使用内建的構造函數
literal notation的優點:
1)it’s shorter to type
2)it emphasizes that objects are simply mutable hashes and not something that needs to be baked from a “recipe” (from a class)
3) faster
技術改變世界
1. 動态添加對象的屬性和方法
2. 一次性建立對象
3. 使用内建的構造函數
literal notation的優點:
1)it’s shorter to type
2)it emphasizes that objects are simply mutable hashes and not something that needs to be baked from a “recipe” (from a class)
3) faster
技術改變世界