JavaScript Timing

Click "Try it". Wait 2 seconds, and the page will alert "Hello".

Click "Stop" to prevent the first function to execute.

(You must click "Stop" before the 2 seconds are up.)