title: Using reduce to sum the price of objects in an array
body: <p>I have an array of objects that have a price property, and I'm trying to sum all the prices in the object. I think what's tripping me up is that it's an array of objects so I'm having a hard time accessing the price property. </p>
  
  <p>Here's what's displaying in the console: <code>0[object Object][object Object][object Object][object Object][object Object][object Object][object Object]</code></p>
  
  <p>Here's my code:</p>
  
  <pre><code>const items = [
      { name: 'Bike', price: 100 },
      { name: 'TV', price: 200 },
      { name: 'Album', price: 10 },
      { name: 'Book', price: 5 },
      { name: 'Phone', price: 500 },
      { name: 'Computer', price: 1000 },
      { name: 'Keyboard', price: 25 }
  ];
  const totalPrice = items.reduce((total, curVal) =&gt; {
      return total + curVal;
  }, 0);
  </code></pre>