JavaScript program is made up with series of statements and each statement ends with a new line or semicolon.
Its not compulsory to terminate a statement with semicolon as JavaScript interpreter use a process called Automatic Semicolon Insertion(ASI). This process will attempt to place semicolons at the end of the line for you.
But, it is best practice to write statement in a new line and terminate by a semi-colon.
JavaScript beginner tutorial
Its not compulsory to terminate a statement with semicolon as JavaScript interpreter use a process called Automatic Semicolon Insertion(ASI). This process will attempt to place semicolons at the end of the line for you.
But, it is best practice to write statement in a new line and terminate by a semi-colon.
JavaScript beginner tutorial
Comments
Post a Comment