If the program is correctly installed then you usually start GAP by
simply
typing gap at the prompt of your operating system followed by the
return key, sometimes this is also called the newline key.
$ gapGAP answers your request with its beautiful banner and then it shows its own prompt
gap> asking you for further input.
(You can avoid the banner with the command line option -b;
more command line options are described in
Section Command Line Options in the reference manual.)
gap>The usual way to end a GAP session is to type
quit; at the gap>
prompt. Do not omit the semicolon!
gap> quit; $On some systems you could type ctl-
D to yield the same effect.
In any situation GAP is ended by typing ctl-C twice within a
second. Here as always, a combination like ctl-D means that you have
to press the D key while you hold down the ctl key.
On some systems (for example the Apple Macintosh) minor changes might be necessary. This is explained in chapter Installing GAP in the reference manual.
In most places whitespace characters (i.e. spaces, tabs and returns) are insignificant for the meaning of GAP input. Identifiers and keywords must however not contain any whitespace. On the other hand, sometimes there must be whitespace around identifiers and keywords to separate them from each other and from numbers. We will use whitespace to format more complicated commands for better readability.
A comment in GAP starts with the symbol # and continues to the
end of the line. Comments are treated like whitespace by GAP. We use
comments in the printed examples in this tutorial to explain certain
lines of input or output.
You should be able to reproduce the results of the examples of GAP sessions in this manual, in the following sense. If you start the GAP session with the two commands
gap> SizeScreen( [ 72, ] ); LogTo( "erg.log" );(which are used to set the line length to 72 and to save a listing of the session on some file), then choose any chapter and rerun its examples in one continuous session and in the given order, the GAP output should look like the output shown in the manual, except for a few lines of output which we have edited a little bit with respect to blanks or line breaks in order to improve the readability. However, when random processes are involved, you may get different results if you extract single examples and run them separately.
GAP 4 manual