350-401 · Question #499
Which JSON script is properly formatted? A. B. C. D.
The correct answer is C. { "furniture": [ { "type": "sofa", "material": "cloth", "color": "blue" } ] }. Option C is correctly formatted JSON because it uses a curly brace {} to define an object, contains an array [] assigned to the 'furniture' key, and that array holds a properly structured object with valid key-value pairs - all following JSON syntax rules. JSON arrays [] contain
Question
Which JSON script is properly formatted? A. B. C. D.
Options
- A{ "Plates": { "use": "salad", "material": "porcelain", "shape": "round" } }
- B[ "Auto": { "maker": "Plymouth", "color": "green", "year": "1970" } ]
- C{ "furniture": [ { "type": "sofa", "material": "cloth", "color": "blue" } ] }
- D[ "Lodging": { "type": "motel", "address": "123 Main Street", "contact": "348-059-6776" } ]
How the community answered
(26 responses)- B4% (1)
- C88% (23)
- D8% (2)
Explanation
Option C is correctly formatted JSON because it uses a curly brace {} to define an object, contains an array [] assigned to the 'furniture' key, and that array holds a properly structured object with valid key-value pairs - all following JSON syntax rules. JSON arrays [] contain indexed values or objects, while JSON objects {} contain key-value pairs, and C correctly nests these structures together.
Topics
Community Discussion
No community discussion yet for this question.