// Rem Example
/* This example does absolutely nothing */
/* It doesn't even have a single line of
executable code */
No edit summary |
No edit summary |
||
(4 intermediate revisions by 4 users not shown) | |||
Line 5: | Line 5: | ||
== Description == | == Description == | ||
Rem is used to include remarks, or comments, as text which is never executed, in a program. The optional component, ''remarks'', is any text. If used as the last of multiple statements on a single line, | Rem is used to include remarks, or comments, as text which is never executed, in a program. The optional component, ''remarks'', is any text. If used as the last of multiple statements on a single line, Rem must be separated from the previous statement by a colon (:). The apostrophe (') synonym is similar to using Rem, but no space is required between the apostrophe and the remarks, and no separating colon is needed on multi-statement lines. | ||
Do not put the string </script> into a comment - it will stop the interpretation of the code. | |||
== Example == | == Example == | ||
< | <tabber> | ||
JavaScript= | |||
<syntaxhighlight lang="JavaScript"> | |||
// Rem Example | |||
/* This example does absolutely nothing */ | |||
/* It doesn't even have a single line of | |||
executable code */ | |||
</syntaxhighlight> | |||
|-| | |||
BASIC= | |||
<syntaxhighlight lang="vb.net"> | |||
Rem Rem Example | Rem Rem Example | ||
Rem This example does absolutely nothing | Rem This example does absolutely nothing | ||
'It doesn't even have a single line of | 'It doesn't even have a single line of | ||
'executable code | 'executable code | ||
</ | </syntaxhighlight> | ||
</tabber> | |||
== Output == | == Output == | ||
Line 23: | Line 36: | ||
[[Category:Language Reference]] | [[Category:Language Reference]] | ||
[[Category:Statements - Flow of control]] |
Rem remarks
'remarks
Rem is used to include remarks, or comments, as text which is never executed, in a program. The optional component, remarks, is any text. If used as the last of multiple statements on a single line, Rem must be separated from the previous statement by a colon (:). The apostrophe (') synonym is similar to using Rem, but no space is required between the apostrophe and the remarks, and no separating colon is needed on multi-statement lines.
Do not put the string </script> into a comment - it will stop the interpretation of the code.
// Rem Example
/* This example does absolutely nothing */
/* It doesn't even have a single line of
executable code */
Rem Rem Example
Rem This example does absolutely nothing
'It doesn't even have a single line of
'executable code