If 2 of 3 Checkboxes are Checked, then Set Value to 1
I have a form, with rows/columns of checkboxes. What I need to do is, in a row, if any 2 of the 3 checkboxes in that row are checked, set the value of a textbox at the end of that row, to '1'. Else, the value of the textbox should be '0'.
I'm wondering if there's a better way to accomplish that, other than writing a sloppy if/then/else statement on the mouse click event for every checkbox?
Here's an example of the form:

