Exercise 4, counting average for ratings