Hello folks! I am have been able to find the sum of the ratings for all the movies directed by Christopher Nolan. But I am struggling to find the mean(average). I know that it can be found by dividing the sum by the total number of movies, which is four, but I do not know exactly how to do that.

This is my code so far.

```
function getRating(watchList) {
return watchList.reduce((average, movie, index) => movie.Director === "Christopher Nolan" ? (+movie.imdbRating + average): average
, 0);
}
```

PS: the best solution I can think of is dividing the sum by the last index. But I don’t know how to put that into code.

Any help would be appreciated. Thank you.

**Your browser information:**

User Agent is: `Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:104.0) Gecko/20100101 Firefox/104.0`

**Challenge:** Functional Programming - Use the reduce Method to Analyze Data

**Link to the challenge:**