I need to take the value of several checkboxes and add them to an input, I did this with an array, the point is that each checkbox has a counter, and I need to add the count