Switch button

Where pengaturanya by pressing the button a few times.
Example I want to turn on by pressing the button 4 times. Less than that the light will not turn on.
How is the syntax code?

The syntax code is doing well, Thanks for asking.

In the IDE go to File, Examples, Digital. There is an example called state change detection that does what you want.