The TWENEX.ORG Pascal compiler was originally developed at the University of Hamburg as “DECSystem-10 Pascal”. The compiler was later modified and distributed by Rutgers University with fixes and updates contributed by CMU, Stanford, USC, Sandia National Laboratories and other sites.
The compiler can be invoked either with the standard compile/load/execute commands or directly with the EXEC command PASCAL
. The standard extension for Pascal source files is .PAS
.
To create and run a Hello, World! program in Pascal:
[KANKAN] PUBLIC:<~>@ create hello.pas
Your default text editor will start. Enter and save the following:
(* Hello program in Pascal *) program Hello (Output); begin writeln ('Hello, World!'); end.
Return to EXEC then compile and run the program:
[KANKAN] PUBLIC:<~>@ execute hello PASCAL: HELLO LINK: Loading [LNKXCT HELLO execution] OUTPUT : Hello, World! [KANKAN] PUBLIC:<~>@
EXECUTE filename[.extension]
. The file extension is optional if you used the standard source file extension (.PAS
) and there are no other program source files with the same name in your default directory.OUTPUT :
prompt, press Enter
to direct output to your terminal.
Additional information on the Pascal compiler can be found in HELP PASCAL
. (The help file mentions a second Pascal compiler, PASSGO, which is not available on TWENEX.ORG.) Additional documentation is in the following files in directory NEO:<DOCUMENTATION>
(DOC:
):
The following is a reference on the ISO Pascal language standard: