Uncheck a checkbox if another checbox is checked

The function adds event handlers to all checkboxes already (this is why we use the for loop).