Information Technology Reference
In-Depth Information
Fig. 4.3. A simplified evolutionary graph
of popular programming languages. The
language styles are marked by different
color frames: red - declarative, blue -
imperative (procedural), and green -
object oriented.
FORTRAN
COBOL
LISP
ALGOL60
Basic
PL/I
Simula67
SNOBOL
ALGOL68
PASCAL
C
Smalltalk
ML
Ada
Modula 2
Common LISP
C++
Python
Java
Programming languages are artificial languages designed to communicate
instructions to a computer. FORTRAN and most other programming languages
consist of sequences of text, including words, numbers, and punctuation
marks. Programming languages may be divided into two broad categories,
imperative and declarative languages ( Fig. 4.3 ). Roughly speaking, imperative lan-
guages specify how a computation is to be done, while declarative languages
focus on what the computer is supposed to do. FORTRAN was the first commer-
cial example of an imperative language. A year later, in 1958, John McCarthy
and his students at the Massachusetts Institute of Technology (MIT) developed
LISP, standing for LISt Processing, a programming language targeted at artifi-
cial intelligence (AI) applications. LISP was the first attempt at creating a type of
declarative language in which computation proceeds by evaluating functions.
In computer programming, a variable is a symbol or name that stands
for a location in the computer's memory where data can be stored. Variables
are important because they enable programmers to write flexible programs.
Rather than putting data directly into the program, the programmer can use
variables to represent the data, allowing the same program to process different
sets of information, depending on what is stored in the computer's memory.
Instructions known as declaration statements specify the sort of information each
variable can contain, called the data type .
Many of the main ideas of the original FORTRAN language are still used in
programming languages today. Features of early versions of FORTRAN were:
Variable names in a FORTRAN program could be up to six characters
long and could change their values during execution of the program.
Variable names beginning with the letters I, J, K, L, M, or N represented
integers , that is, whole numbers with no fractional parts. All other vari-
ables represented real numbers , which could be any positive or negative
numbers, including integers.
Boolean variables, variables that have the value of either true or false,
could be specified with a logical declaration statement.
Five basic arithmetic operations were supported: + for addition; - for
subtraction; * for multiplication; / for division; and ** for exponentia-
tion, raising one quantity to the power of another.
Search WWH ::




Custom Search