Step: Test

Test

Let's put it all together.

Input:
{
  "firstName": "Charles",
  "lastName": "Doe",
  "age": 41,
  "location": {
    "city": "San Francisco",
    "postal-code": "94103"
  },
  "hobbies": [
    "chess",
    "netflix"
  ],
  "pets": [
    {
      "name": "Bear",
      "kind": "dog"
    },
    {
      "name": "Jerry",
      "kind": "cat"
    }
  ]
}
Expected:
{
  "name": "Doe, Charles",
  "city": "San Francisco"
}