You should be getting a syntax error in the console pane. Look at that closely as it is giving you a hint as to where the problem is.
Also, you replaced the 0 with the variable c as the second argument in the reduce method. The variable c hasn’t been defined. It’s not a good idea to use it without defining it.