Programmer's Guide to the Zeno Interpreter
Appendix A. Elements of the Zeno programming language
A summary of the elements of the language are shown in this appendix.
conventions
- An italicized item is an elements of code determined by the programmer.
- A bracketed [item] is optional.
- Items in braces {item} are optional and may be repeated.
elements
A Zeno program is made up of:
declarations
subprograms
A subprogram is one of:
- The main program:
program
declarations and statements
end program
- A subprogram that returns a value on the stack:
function name( parameter{, parameter} ) : type specification
declarations and statements
end function
or, if there are no parameters:
function name : type specification
declarations and statements
end function
- A subprogram that operates on data without returning a value on the stack.
procedure name( parameter{, parameter} )
declarations and statements
end procedure
or, if there are no parameters:
procedure name
declarations and statements
end procedure
A formal parameter is:
[var] name{, name} : type specification
|