next up previous contents
Next: User Defined Variables (Identifiers) Up: Input Syntax Previous: How to Input a

Special Characters

 

The following characters have special meaning in Macaulay.

displaymath5395

The characters ``>, <, <<, >>, #, $, @, &'' all have meaning when used with script files. The characters ``>, <, <<, >>'' redirect either the input or the output of Macaulay, when they appear at the beginning of a line or a parameter. The characters ``<, <=, >, >=, =, !='' have their usual meaning as relational operators if they appear in an integer or polynomial expression.

The character ``#'' is used for arguments to scripts, the character ``@'' is used to provide some support for local variables, and the character ``$'' is used to exit a script. This last character, if typed outside of a script, causes Macaulay to exit exactly as if ``exit'' had been typed, so be careful! See Chapter 11 for more details.

The characters ``;'', ``?'' and ``%'' are used for comments. Any text appearing after a semicolon is ignored (to the end of the line). Text appearing before a ``?'' or ``%'' on an input line is also ignored. This allows the user to place comments either at the beginning or at the end of the line. This was included mainly for use with the Macintosh MPW shell: when one types ``<enter>'', the entire current line is sent as input to Macaulay. Macaulay's prompts for input always end with either a ``?'' or ``%''. Therefore the prompt part of the line is considered a comment by Macaulay! An additional benefit is that a Macaulay session (recorded with monitor for example) can be ``played back'' as an input file.



Sorin Popescu
Fri Feb 14 17:37:19 EST 1997