mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2025-08-09 08:16:58 +02:00
Update red.html.markdown
Added header info and completed Hello World program with the header.
This commit is contained in:
@@ -23,15 +23,22 @@ from any platform to any other platform. And it will do this all from a binary e
|
|||||||
Ready to learn your first Red?
|
Ready to learn your first Red?
|
||||||
|
|
||||||
```Red
|
```Red
|
||||||
|
All text before the Red header will be treated as comment
|
||||||
|
The Red header is the word "Red" followed by a whitespace character followed by a block of square brackets [].
|
||||||
|
The block of brackets can be filled in with useful information about the script or program, the author, the version, the license, what the program does or needs.
|
||||||
|
The Red/System header is just like the Red header, only saying "Red/System" and not "Red".
|
||||||
|
|
||||||
|
Red []
|
||||||
|
|
||||||
;this is a commented line
|
;this is a commented line
|
||||||
|
|
||||||
print "hello world" ; this is another comment
|
print "Hello Red World" ; this is another comment
|
||||||
|
|
||||||
comment {
|
comment {
|
||||||
This is a
|
This is a
|
||||||
multiline
|
multiline
|
||||||
comment
|
comment.
|
||||||
|
You just saw the Red version of the "Hello World" program.
|
||||||
}
|
}
|
||||||
|
|
||||||
; Your program's entry point is the first executable code that is found
|
; Your program's entry point is the first executable code that is found
|
||||||
|
Reference in New Issue
Block a user