I'm working on a problem and would like to use array methods to solve it. 

My code below I think is close but i can't get it to return the right number. 

Goal: Create a function that returns the sum of all even elements in a 2D matrix.

```
function sumOfEvens(arr) {

  // filter for events, push to new array, then sum

  let evenArr=arr.reduce((a,e) => a.concat(e) ,[])
  return evenArr.reduce((a,e) => {
    if (e%2===0){
      console.log(e)
     a+e;
    }
  },0) 
}

sumOfEvens([
  [1, 0, 2],
  [5, 5, 7],
  [9, 4, 3]
]) //➞ should return 6

```

My output is undefined but my console log returns correctly: 
[![enter image description here](https://i.stack.imgur.com/1cBNV.png)](https://i.stack.imgur.com/1cBNV.png)