Write a clean and well organize script tag is important. Dreamweaver and most other code editor do provide an automatic and autocomplete tag pair feature.
To ensure you set it, go to Edit –> Preferences…
Then, on Code Hints tab, select the 2nd radio button of Close tags option , which is After typing the open tag’s “>”
Save it. You are now set and ready!