From 7b84e2d4f4271ad01d4b87a3d4f28ee5e92d81e7 Mon Sep 17 00:00:00 2001 From: Eric Leung Date: Mon, 4 Jul 2016 01:14:29 -0700 Subject: [PATCH] Rewrite Manipulating Complex Objects for clarity --- .../basic-javascript.json | 20 ++++++++----------- 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/challenges/01-front-end-development-certification/basic-javascript.json b/challenges/01-front-end-development-certification/basic-javascript.json index 5d1cae4c2d..74c127c902 100644 --- a/challenges/01-front-end-development-certification/basic-javascript.json +++ b/challenges/01-front-end-development-certification/basic-javascript.json @@ -4330,20 +4330,16 @@ "id": "56533eb9ac21ba0edf2244cb", "title": "Manipulating Complex Objects", "description": [ - "JavaScript objects are flexible because they allow for Data Structures with arbitrary combinations of strings, numbers, booleans, arrays, functions, and objects.", - "Here is an example of a complex data structure:", + "Sometimes you may want to store data in a flexible Data Structure. A JavaScript object is one way to handle flexible data. They allow for arbitrary combinations of strings, numbers, booleans, arrays, functions, and objects.", + "Here's an example of a complex data structure:", "
var ourMusic = [
{
\"artist\": \"Daft Punk\",
\"title\": \"Homework\",
\"release_year\": 1997,
\"formats\": [
\"CD\",
\"Cassette\",
\"LP\" ],
\"gold\": true
}
];
", - "This is an array of objects and the object has various pieces of metadata about an album. It also has a nested formats array. Additional album records could be added to the top level array.", - "Note
You will need a comma in between objects with more than one object in the array.", - "JavaScript Object Notation or JSON is a data interchange format used to store data (source: json.org).", - "A property is the part of an object that associates a key (either a String value or a Symbol value) and a value (source: ecma-international.org/ecma-262/6.0/#sec-property). So, a property consists of a key - value pair. (source: spacetelescope.github.io/understanding-json-schema/reference/object.html#properties). Property keys (also known as names) should be in quotation marks.", - "Like JavaScript Objects, JSON is flexible because it is heterogeneous, meaning it permits Data Structures with arbitrary combinations of strings, booleans, numbers, arrays, and objects.", - "Here is an example of a JSON object:", - "
var ourMusic = [
{
\"artist\": \"Daft Punk\",
\"title\": \"Homework\",
\"release_year\": 1997,
\"formats\": [
\"CD\",
\"Cassette\",
\"LP\" ],
\"gold\": true
}
];
", - "This is an array of objects and the object has various pieces of metadata about an album. It also has a nested formats array. Additional album records could be added to the top level array.", - "Note
You will need to place a comma in between objects in JSON unless there is only one object in the array or containing object.", + "This is an array which contains one object inside. The object has various pieces of metadata about an album. It also has a nested \"formats\" array. If you want to add more album records, you can do this by adding records to the top level array.", + "Objects hold data in a property, which has a key-value format. In the example above, \"artist\": \"Daft Punk\" is a property that has a key of \"artist\" and a value of \"Daft Punk\".", + "JavaScript Object Notation or JSON is a related data interchange format used to store data.", + "
{
\"artist\": \"Daft Punk\",
\"title\": \"Homework\",
\"release_year\": 1997,
\"formats\": [
\"CD\",
\"Cassette\",
\"LP\"
],
\"gold\": true
}
", + "Note
You will need to place a comma in between every object in the array, unless it is the last object in the array.", "

Instructions

", - "Add a new album to the myMusic object. Add artist and title strings, release_year number, and a formats array of strings." + "Add a new album to the myMusic array. Add artist and title strings, release_year number, and a formats array of strings." ], "releasedOn": "January 1, 2016", "challengeSeed": [