title: Reduce method in order to count object values with a specific keys
body: <p>I have an array like this:</p>
  
  <pre><code>const teamsPoints = [
    {team1_game00: 1},
    {team1_game01: 2},
    {team1_game02: 3},
    {team2_game00: 0},
    {team2_game10: 2},
    {team2_game11: 3},
    {team3_game01: 0},
    {team3_game10: 0},
    {team3_game20: 3},
    {team4_game02: 0},
    {team4_game11: 0},
    {team4_game20: 0}
  ]
  </code></pre>
  
  <p>What I'm trying to get is:</p>
  
  <pre><code>{
    team1: 6,
    team2: 5,
    team3: 3,
    team4: 0
  }
  </code></pre>
  
  <p>which is the sum of points of every team.</p>
  
  <p>I was trying to achieve that by using reduce method.</p>
  
  <pre><code>const scoreResult = teamsPoints.reduce((total, current) =&gt; {    
  
  }, {});
  </code></pre>
  
  <p>As I understand I'm starting with an empty object, but then I have a problem to get proper key-value pairs (that's why I have not published it here, must admin reduce method is a kinda new thing to me).</p>
  
  <p>Thank you in advance!</p>