Multi-line comments begin with /*
and end with */
.
Any text between /*
and */
will be ignored.
The following example demonstrates a multi-line comment for explanation:
Multi-line comment for explanation:
/* |
We can use multi-line comments to prevent entire blocks of code from being executed.
Multi-line comment to exclude code:
/* |
The multi-line comment syntax can also be used to prevent the execution of parts within a line of code.
The +15
portion will be ignored in the calculation.
$x |