Here you can find a number of examples on Java Script.Please find the various kinds of examples listed on the right side of this site. If you don't find anything on Java Script then please write to us or leave a commnet. We are pleased to help and find the solution of your problem.

JavaScript Comments

Earn 5000 a day

When Programming, it is good to write the comments around the code so that you know what it is doing and so people reading your code knows what it is doing.

When you add single line comment in JavaScript then start with //.

This example uses single line comments to explain the code:

<script language="javascript">
//single line Comment
document.write("This is JavaScript");
document.write("HELLO"); //this will write HELLO

JavaScript Multi-line Comments

If you want to add Multi line comments in your JvaSript code then start with /* and end with */.

Example on Multi line comment :

<script language="javascript">
The code below will write
one header and two paragraphs
document.write("<h1>This is a header</h1>");
document.write("<p>This is a paragraph</p>");
document.write("<p>This is another paragraph</p>");