Conventions used

There are a number of text conventions used throughout this book.

CodeInText: Indicates code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles. Here is an example: "The console executable is built inside the /home/user/.red folder and is named in the format console-yyyy-m-dd-nnnnn."

A block of code is set as follows:

Red [
Name-Of-Info: "Value of Info"
Name-Of-Info2: "Value of Info2"

...
]

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

a: [1 2 3]
b: copy a
b ;== [1 2 3]
append a 4
a ;== [1 2 3 4]
b ;== [1 2 3]

You can find the code in the codefile that accompanies each section. At the start of each code snippet, you'll see:

;-- see ChapterNN/codefile.red:

This means that this snippet is found in the file ChapterNN/codefile.red in the code download (where NN goes from 01 to 10), as well as the code snippets shown after that, until a new codefile is indicated.

We'll use the terms program, script, app or application as synonyms in this book, because a Red source file can be compiled or interpreted.

We show the return value of a piece of code after ;== like  a: 5  ;== 5, because == is how the Red console displays it, and the prefix ; makes it into a comment in scripts.

We have chosen to make all programs immediately runnable in the console without errors. However, certain code is there explicitly to make you see certain errors. These are indicated with a comment: *** Script Error …. Just remove the comment (;) sign at the start of the line to make the error occur.
The same goes for lines staring with #include, just uncomment them in order to compile the program.

Any command-line input or output is written as follows:

$ sudo apt-get update

Bold: Indicates a new term, an important word, or words that you see onscreen. For example, words in menus or dialog boxes appear in the text like this. Here is an example:
"From the menu, open File | Run.
"

Warnings or important notes appear like this.
Tips and tricks appear like this.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.227.161.225