Basic Syntax
Some of the basic rules for JavaScript are below:
1.JavaScript borrows most of its syntax from Java.
2.JavaScript is case sensitive.
3.Single line comments begin with //
4.Multiline comments begin with /* and end with */
5.Statements terminate with semicolons.
6.Curly brackets are used for blocks.
<script type="text/javascript">
{
document.write("hello world");
}
</script>
{
document.write("hello world");
}
</script>
No comments:
Post a Comment