This commit is contained in:
Ingy döt Net 2013-04-10 21:29:02 -07:00
parent 764da6cbbb
commit db842d013d
19005 changed files with 197040 additions and 7 deletions

View file

@ -0,0 +1 @@
{comments are in curly braces}

View file

@ -0,0 +1,3 @@
! Comments starts with "! "
#! Or with "#! "
! and last until the end of the line

View file

@ -0,0 +1,6 @@
/* Start comment block
My Life Story
*/
// set up my bank account total
bank_account_total = 1000000 // Wish this was the case

View file

@ -0,0 +1,2 @@
# Comments starts with "#"
# and last until the end of the line

View file

@ -0,0 +1,4 @@
v This is the Fish version of the Integer sequence task
>0>:n1+v all comments here
^o" "< still here
And of course here :)

View file

@ -0,0 +1 @@
# Comment (till end of line)

View file

@ -0,0 +1 @@
// comment starts with "//" and continues to the end of the line

View file

@ -0,0 +1,6 @@
/* a multi-line comment starts with slash-asterisk and,
ends with asterisk-slash.
also note:
* A multi-line comment is ignored inside a string
* A multi-line comment can be ended inside a line
*/

View file

@ -0,0 +1,2 @@
100 REM Standard BASIC comments begin with "REM" (remark) and extend to the end of the line
110 PRINT "this is code": REM comment after statement

View file

@ -0,0 +1,2 @@
' This whole line is a comment and is ignored by the gambas interpreter
print "Hello" ' Comments after an apostrophe are ignored

View file

@ -0,0 +1 @@
! comment starts with "!" and continues to end of line

View file

@ -0,0 +1 @@
# end of line comment

View file

@ -0,0 +1,7 @@
// Single line commment.
/*
Multiple
line
comment.
*/

View file

@ -0,0 +1 @@
! a comment starts with a "!" and ends at the end of the line

View file

@ -0,0 +1,2 @@
; The following computes the factorial of a number "n"
fact = product(indgen( n )+1) ; where n should be an integer

View file

@ -0,0 +1,3 @@
# This is a comment
procedure x(y,z) #: This is a comment and an IPL meta-comment for a procedure

View file

@ -0,0 +1,6 @@
[This is a single-line comment.]
[This is a
multi-line comment.]
[Comments can [be nested].]

View file

@ -0,0 +1,6 @@
# Single-line comment
// Single-line comment
/* Multi-line
comment */

View file

@ -0,0 +1,11 @@
NB. Text that follows 'NB.' has no effect on execution.
0 : 0
Multi-line comments may be placed in strings,
like this.
)
Note 'example'
Another way to record multi-line comments as text is to use 'Note', which is actually
a simple program that makes it clearer when defined text is used only to provide comment.
)

View file

@ -0,0 +1 @@
//* This is a comment line (//* in columns 1-3)

View file

@ -0,0 +1,4 @@
# this is a single line comment
(* this is a
multi-line comment *)

View file

@ -0,0 +1,2 @@
/ this is a comment
2+2 / as is this

View file

@ -0,0 +1,8 @@
//This is a comment.
//This is another comment.
/* This is a comment too. */
/* This is a
multi-line
comment */

View file

@ -0,0 +1 @@
# single line comment (space after # is required)

View file

@ -0,0 +1 @@
# arg1 arg2 '''yields''' result|''nothing''

View file

@ -0,0 +1 @@
# This is a comment.

View file

@ -0,0 +1,5 @@
'This is a comment
REM This is a comment
print "This has a comment on the end of the line." 'This is a comment
print "This also has a comment on the end of the line." : REM This is a comment

View file

@ -0,0 +1,4 @@
% This is a comment
%{ This is a comment
spanning several lines %}

View file

@ -0,0 +1 @@
; comments come after a semicolon, and last until the end of the line

View file

@ -0,0 +1 @@
% single-line comment; extends to the end of the line

View file

@ -0,0 +1,2 @@
/* multi-line
comment */

View file

@ -0,0 +1 @@
' This is a comment

View file

@ -0,0 +1,4 @@
%REM
This is a multi-
line comment.
%END REM

View file

@ -0,0 +1,6 @@
eval(2*3) # eval(2*3) "#" and text after it aren't processed but passed along
dnl this text completely disappears, including the new line
divert(-1)
Everything diverted to -1 is processed but the output is discarded.
A comment could take this form as long as no macro names are used.
divert

View file

@ -0,0 +1,4 @@
-- Two dashes precede a single line comment
/* This is a
multi-line comment */

View file

@ -0,0 +1,6 @@
! A pling in a line starts a comment
INT n:=5 ! Comments can appear at the end of a line
/* A comment block can also be defined using climbstar and starclimb symbols.
This allows comments to be stretched across several lines */

View file

@ -0,0 +1,3 @@
"String literals are technically the only long-term comment format";
// Some compilers will, however, compile // one-liners to string literals as well (and vice-versa)
/* Classical C-style comments are removed entirely during compile */

View file

@ -0,0 +1 @@
(*this is a comment*)

View file

@ -0,0 +1 @@
If[a(*number 1*)<(* is smaller than number 2*) b, True (*return value (*bool true*)*), False (*return bool false*)]

View file

@ -0,0 +1 @@
If[a < b, True, False]

View file

@ -0,0 +1,3 @@
/* Comment
/* Nested comment */
*/

View file

@ -0,0 +1 @@
% this is "to-end-of-line" comment

View file

@ -0,0 +1,4 @@
puts 'code' # I am a comment
/* This is
* a multiple
* line comment */

View file

@ -0,0 +1,3 @@
(* Comments (* can nest *)
and they can span multiple lines.
*)

View file

@ -0,0 +1,3 @@
(* Comments (* can nest *)
and they can span multiple lines.
*)