To set all numeric variables to zero, all string variables to null, and to close all open files. Options set the end of memory and reserve the amount of string and stack space available for use by GW-BASIC.
expression1 is a memory location that, if specified, sets the maximum number of bytes available for use by GW-BASIC.
expression2 sets aside stack space for GW-BASIC. The default is the previous stack space size. When GW-BASIC is first executed, the stack space is set to 512 bytes, or one-eighth of the available memory, whichever is smaller. GW-BASIC allocates string space dynamically. An "Out of String Space" error occurs only if there is no free memory left for GW-BASIC to use.
The CLEAR command:
Zeroes variables and nulls all strings.
Zeroes variables, nulls strings, protects memory above 32768, does not change the stack space.
Zeroes variables, nulls strings, allocates 2000 bytes for stack space, and uses all available memory in the segment.
Zeroes variables, nulls strings, protects memory above 32768, and allocates 2000 bytes for stack space.