title: how to extract values from an object nested inside array inside object and store it in different arrays JAVASCRIPT
body: <pre><code>[{
      &quot;_id&quot;: &quot;5fd6288a155cda5a10d067fa&quot;,
      &quot;contacts&quot;: [
          {
              &quot;_id&quot;: &quot;5fd6288a155cda5a10d067fb&quot;,
              &quot;id&quot;: &quot;5fd35931ec23f76d387d8464&quot;,
              &quot;name&quot;: &quot;dean&quot;
          },
          {
              &quot;_id&quot;: &quot;5fd6288a155cda5a10d067fc&quot;,
              &quot;id&quot;: &quot;12&quot;,
              &quot;name&quot;: &quot;john&quot;
          },
          {
              &quot;_id&quot;: &quot;5fd6288a155cda5a10d067fd&quot;,
              &quot;id&quot;: &quot;1&quot;,
              &quot;name&quot;: &quot;brad&quot;
          }
      ],
      &quot;messages&quot;: [],
      &quot;__v&quot;: 0
  },
  {
      &quot;_id&quot;: &quot;5fd63ab97aac3826f8e64558&quot;,
      &quot;contacts&quot;: [
          {
              &quot;_id&quot;: &quot;5fd63ab97aac3826f8e64559&quot;,
              &quot;id&quot;: &quot;5fd35931ec23f76d387d8464&quot;,
              &quot;name&quot;: &quot;dean&quot;
          },
          {
              &quot;_id&quot;: &quot;5fd63ab97aac3826f8e6455a&quot;,
              &quot;id&quot;: &quot;12&quot;,
              &quot;name&quot;: &quot;brad&quot;
          }
      ],
      &quot;messages&quot;: [],
      &quot;__v&quot;: 0
  }]
  </code></pre>
  <p>Quick overview: each object contains a different conversation data.
  I want to extract the names out of each conversation and store them in a separate array.
  for instance: <code>[[dean, john, brad], [dean, brad]]</code></p>