Problems tracking pin state with Switch statement

First auto format your code before YOU try to debug it.

Second look in the playground for button/switch debounce.

Mark