1<!--
2 Method 1: external script
3 - Should be placed in the <head> section of your HTML
4 - The 'src' should contain the path to a local file or external URL
5 - The 'defer' attribute will make it execute after the DOM is loaded
6-->
7<script src="script.js" type="text/javascript"></script>
8<script src="script.js" type="text/javascript" defer></script>
9
10<!--
11 Method 2: inline code
12 - Should be placed in the <head> or <body> section of your HTML
13 - Place it before the </body> to make it execute after the DOM is loaded
14-->
15<script> alert("Hello world!"); </script>