The following conventions will be observed throughout this document:
Whenever we refer to bits of code from the main text, it will be highlighted like this
. For example:
The
HelloWorld
class has a singlemain
method that prints out a"Hello World"
string.
javac HelloWorld.java
If a command is too long to fit in a single line, it will be wrapped into several lines using the backslash ("\") character. On most UNIX shells (including BASH) you should be able to copy and paste all the lines at once into your console.
javac \ -classpath /usr/lib/java/Hello.jar \ HelloWorld.java \ HelloUniverse.java \ HelloEveryone.java
You can find three types of notes in the text: complementary information, reminders, and warnings.
This is a complementary information block. This kind of note contains interesting information that complements what is currently being discussed in the text. |
This is a reminder. This kind of notes are usually used after a block of code to remind you of where you can find the file that contains that particular code. It is also used to remind you of important concepts, and to suggest what sections of the tutorial you should read again if you have a hard time understanding a particular section. |
This is a warning. Warnings are used to emphatically point out something. They generally refer to common pitfalls or to things that you should take into account when writing your own code. |