Node:Conventions Used in this Book, Previous:Material Covered, Up:Preface



Conventions Used in this Book

In this text, a variety of conventions are used to explain the material. Certain typographical and display elements are used for didactic purposes.

Any Perl code that is included directly in flowing text appears like this: $x = 5. Any operating system commands discussed in flowing text appear like this: program. Operating system files that are discussed directly in the flowing text appear like this: file. When a technical term of particular importance is first introduced and explained, it appears in emphasized text, like this: an important term.

When Perl code examples or operating system commands need to be separated away from the flowing text for emphasis, or because the code is long, it appears like this:

     my $x = "foo";     # This is a Perl assignment
     print $x, "\n";    # Print out "foo" and newline
     

All Perl code shown in this manner will be valid in Perl, version 5.6.0. In most cases, you can paste code from one of these sections into a Perl program, and the code should work, even under use strict and use warnings.

Sometimes, it will be necessary to include code that is not valid Perl. In this case, a comment will appear right after the invalid statement indicating that it is not valid, like this:

     $x = "foo;     # INVALID: a " character is missing
     

When code that we set aside forms an entire Perl program that is self-contained, and not simply a long example code section, it will appear like this:

     #!/usr/bin/perl
     
     use warnings;
     use strict;
     
     print "Hello World\n";
     

Finally, when text is given as possible output that might be given as error messages when perl is run, they will appear like this:

     Semicolon seems to be missing
     syntax error
     

Keep these standards in mind as you read this book.