Counter for times the buttons have been pressed

The state change detection example shows how to count button switch presses. My addition to that tutorial covers state change detection using active low (wired to ground) switches.