Welcome to the Dictionary of Programming Languages, a compendium
of computer coding methods assembled to provide information and
aid your appreciation for computer science history.
Browse the dictionary by clicking on a section:
A
B
C
D
E
F
G
H
I
JK
L
M
N
O
P
QR
S
T
UV
WXYZ+
Get a full dump of the dictionary:
List of Names
Short Form
Full Form
-
Pascal
- Language type:
- Description:
Pascal is a simple block-structured language
originally designed for computer science
education. Pascal features strong type
checking, simple I/O facilities, a
good set of primitive data types,
arrays, fixed and variant records,
conventional control structures, and
simple dynamic memory management.
Pascal requires discipline from the
programmer: all types, data, and subroutines
in a Pascal program must be declared prior
to use. Everything is lexically scoped, to
allow for maximum compile-time type
checking. The language has good support
for programmer-defined data types and
subtypes, which are also subject to strong
checking.
Structure of a Pascal block is somewhat
rigid, elements must appear in a certain
order preceded by their identifying keyword:
labels, constants, types, variables and functions, then
body code.
The original Pascal language borrowed some
structural ideas from Algol, but also
included novel syntactic and
semantic features intended to foster
good structured programming technique (or at least
what was considered sound structured
development technique in the 1970s).
The choice of features and the limited
external interface facilities helped
make Pascal very portable.
However, the initial design was very spare,
it didn't
include strings, only arrays of
characters, and it had a very small
complement of built-in utility functions.
These omissions led developers of Pascal
language implementations to add extensions to
help programmers accomplish real work,
and unfortunately every vendor's extensions
were more-or-less proprietary -- the Pascal
language lost some of its portability.
Amazingly, while it is very strict in
most ways, Pascal still supports a 'goto'
statement.
Pascal does not support object-oriented
programming, persistence, or multi-tasking.
A 1975 variant of Pascal called
"Concurrent Pascal" had good support for
multi-tasking and other advanced features.
Over the 1970s and 1980s,
Pascal became fairly widely used,
especially in the early days of the IBM
PC and the Macintosh. A great many students of computing in
the 80s cut their teeth on Pascal programs.
Both free and commercial Pascal compilers
exist. The most popular commercial
compiler, and a fine language
implementation, is "Turbo Pascal" from
Borland.
Pascal is normally compiled, either to
machine code or virtual machine bytecodes
of some sort. Source-level Pascal interpreters also exist,
and translators from
Pascal to other languages.
Information on Pascal, including
programming tutorials, is widely available
on the WWW.
- Origin:
- See Also:
- Remarks:
Pascal proved to be a very influential
language. First described in a published
report in 1971, it affected almost
every block-structured language designed
since (e.g. Ada). Niklaus Wirth continued
to design programming languages, including
the Modula family.
One of the most interesting aspects of
Pascal is its relative poverty of
features. Compared to its rough contemporary
PL/1, Pascal is a tiny language.
This contrast helped frame a debate that
has raged in computer science circles
ever since: should languages be kept
small and simple (with complex facilities
provided by external libraries), or
should they be made large and complex to
provide all features that programmers
require. Many later block-structured and
object-oriented language designers would
be forced to choose one of these two
camps. Oberon, for example, is small
and spare, depending on libraries for
advanced features. Perl, in contract,
is complex and loads many useful features
in the language itself. Recent
languages like
Java adopt a compromise position: keep
the language simple, but standardize the
supporting libraries to prevent
incompatible implementations.
In most programming areas, Pascal
has been superseded by newer, object-oriented
languages, such C , Java, etc.
- Links:
-
-
-
-
- Date:
- Sample code:
{ Sort program adapted from "Intermediate Pascal" }
{ by Joe Dorward. Illustrates arrays and types. }
program sort_array(input,output);
const
max = 9;
type
integer_array = array[1..max] of integer;
var
I, J, K, swaps, temp : integer;
test_array : integer_array;
begin
test_array[1] := 4; test_array[2] := 7; test_array[3] := 9;
test_array[4] := 3; test_array[5] := 15; test_array[6] := 2;
test_array[7] := 08; test_array[8] := 05; test_array[9] := 12;
writeln(' *** Initial Array ***');
writeln(' --- --- --- --- --- --- --- --- --- ');
for I := 1 to (max-1) do
write('|',test_array[I]:2,' ');
writeln('|',test_array[max]:2,' |');
for I := 1 to max do
for J := (I 1) to max do { set J to start one ahead of I }
if test_array[J] < test_array[I] then
begin
swaps := swaps 1;
temp := test_array[J];
test_array[J] := test_array[I];
test_array[I] := temp;
writeln;
writeln('* * Condition After ',swaps:1,' swaps * *');
writeln(' --- --- --- --- --- --- --- --- --- ');
for K := 1 to (max-1) do
write('|',test_array[K]:2,' ');
write('|',test_array[max]:2,' |');
end;
writeln(' * Sorting Complete *');
end.
Descriptions in this dictionary are ©1997-99 Neal Ziring. Some
examples copyright of their respective authors. Some
technologies and languages are trademarked. Permission to
copy descriptions is granted as long as authorship credit is preserved.
Comments on this dictionary, corrections and suggestions, are all welcome.
Please use email, the address is ziring@home.com
[Ziring MicroWeb Home]
[Dictionary Start]
[Sign Guestbook]
Dictionary and script maintained by Neal Ziring, last major modifications 3/18/98. Most recent
additions to dictionary and master list, 1/00.