JavaScript Programming JavaScript > Code Examples Working with the Increment Operator Working with the Increment Operator <HTML> <HEAD> <TITLE>Happy Codings :-) JavaScript Code Examples</TITLE> </HEAD> <BODY> <H1> <SCRIPT> var Inc = 1; document.write("Starting value of " + Inc + "<BR>"); document.write("IncPreFix " + ++Inc + "<BR>"); document.write("IncPostFix " + Inc++ + "<BR>"); document.write("Ending value of " + Inc); </script> </H1> </BODY> </HTML>