CMSC 124
Design and Implementation of Programming Languages
CNM Peralta
Institute of Computer Science
University of the Philippines Los Baños
A (Brief?) History of
Programming Languages
(Or how 0’s and 1’s gave way to mov ax, bx, and onward to
public static void main(String args[]).)
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 2
Programming Languages
The first programming language was called
Plankalkül
designed by Konrad Zuse.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 3
Programming Languages
Plankalkul
•Fairly complete
•Features:
̶ the usual data types (integer, floating-point, etc.)
̶ arrays and [nested] records (similar to C struct)
̶ Iterative statement similar to Ada’s for
̶ Conditional statement if, but no else clause
̶ Mathematical expressions showed current
relationships between variables
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 4
Programming Languages
Plankalkul
Problem: Each statement consisted of 2-3 lines
A + 1 => A
4 5
1.n 1.n
A[5] = A[4] + 1
…which can be a bit intimidating.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 5
Programming Languages
In the beginning there were
machine languages
but…
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 6
Programming Languages
Machine languages were
error-prone
and
tedious
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 7
Programming Languages
They made use of
numeric codes
to specify instructions
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 8
Programming Languages
Furthermore…
absolute addressing
was used to reference data and other
instructions.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 9
Programming Languages
Such problems prompted the development of
assemblers
and
assembly languages
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 10
Programming Languages
Problem: Most problems required
floating-point arithmetic
and
indexing
for arrays
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 11
Programming Languages
Thus, new, higher-level languages
were developed,
the first of which was called
Short Code
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 12
Programming Languages
Short Code
It was developed by
John Mauchly in 1949
for the BINAC computer.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 13
Programming Languages
Short Code was interpreted,
and was estimated to be
50 times slower
than machine code.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 14
Programming Languages
Some other languages at this time were
Speedcoding
and the
UNIVAC “Compiling” System
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 15
Programming Languages
Speedcoding was developed by
John Backus in 1954.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 16
Programming Languages
It was intended for the
IBM 701.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 17
Programming Languages
Grace Hopper at UNIVAC
developed compiling systems named
A-0, A-1, and A-2.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 18
Programming Languages
These compiling systems
expanded pseudocode to machine
code subprograms
making source programs shorter.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 19
Programming Languages
And then…
With the introduction of the
IBM 704 in 1954
came the development of
FORTRAN.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 20
Programming Languages
The IBM 704 supported both
floating-point arithmetic
and
indexing
in hardware, eliminating the need to
interpret and simulate such operations
using software.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 21
Programming Languages
FORTRAN stands for
“Formula Translator”
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 22
Programming Languages
At the time, computers…
• had small memories
• were used for scientific computations
• had no way of being programmed efficiently
• were so expensive that the priority was speed
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 23
Programming Languages
FORTRAN evolved over the years,
starting with FORTRAN 0.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 24
Programming Languages
FORTRAN 0 was described in
“The IBM Mathematical FORmula TRANslating
System: FORTRAN,”
but was modified during implementation to
eventually produce FORTRAN 1.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 25
Programming Languages
FORTRAN 1 was released in 1957 and featured
Input/output formatting
Variable names with up to 6 characters
User-defined subroutines
If statements
Do loops
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 26
Programming Languages
Claim: Source code compiled using
FORTRAN would produce machine code
that is half as efficient as hand-produced
machine code.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 27
Programming Languages
Truth: The claim was, for the most
part, achieved.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 28
Programming Languages
FORTRAN II appeared in 1958, adding several
features, the most significant of which was
the
independent compilation of
subroutines.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 29
Programming Languages
FORTRAN was updated continuously over the
next years, with FORTRAN IV (aka, FORTRAN
66) being quite popular during the 1960’s.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 30
Programming Languages
The first functional programming
language was invented particularly for
list processing, which was used in
Artificial Intelligence.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 31
Programming Languages
Allen Newell, J. C. Shaw, and Herbert Simon
at RAND Corporation first came up with the
concept of list processing in 1956.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 32
Programming Languages
The language they described was
IPL-I (Information Processing
Language I).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 33
Programming Languages
Although IPL-I (and consequently, IPL-II) did
not see widespread use, they showed the
feasibility and usefulness of list processing.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 34
Programming Languages
IBM also implemented the
Fortran List Processing Language
(FLPL)
as an extension to FORTRAN.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 35
Programming Languages
John McCarthy developed LISP in
1958, called pure LISP because it was
purely functional.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 36
Programming Languages
LISP was meant to cover ground that FLPL
failed to:
Recursion
Conditional expressions
Dynamic storage allocation
Implicit deallocation
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 37
Programming Languages
Eventually, LISP was adapted to two dialects
commonly used today:
SCHEME (1970’s)
and
Common LISP (1994)
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 38
Programming Languages
Problem: Although languages were now
high-level, they were still
machine-dependent.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 39
Programming Languages
The first effort to design a universal
programming language for
scientific applications resulted in ALGOL
60.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 40
Programming Languages
On May 10, 1957, several computing groups
petitioned the Association for Computing
Machinery (ACM) to form a committee to
study the possibility of creating a
machine-independent programming
language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 41
Programming Languages
The Society for Applied
Mathematics and Mechanics
(German abbrev. GAMM) also wrote ACM
to collaborate, and in April 1958, a joint
language project was agreed upon.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 42
Programming Languages
The first meeting, held in 1958,
took place in Zurich.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 43
Programming Languages
The committee had several goals for the
new language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 44
Programming Languages
1.
Syntax should be as close as possible to
mathematical notation,
and programs should be
readable
with little explanation.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 45
Programming Languages
2.
Language must be able to
describe algorithms
in printed publications.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 46
Programming Languages
3.
Source code should be
mechanically translatable
to machine language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 47
Programming Languages
After the joint meeting, the language was first
called International Algorithmic Language
(IAL) but was eventually renamed to
ALGOL (ALGOrithmic Language).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 48
Programming Languages
ALGOL can be thought of as a
descendant of FORTRAN.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 49
Programming Languages
ALGOL
generalized
FORTRAN.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 50
Programming Languages
1.
ALGOL formalized the concept
of
data types.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 51
Programming Languages
2.
Added the idea of
compound statements.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 52
Programming Languages
3.
Identifiers could have
any length.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 53
Programming Languages
4.
Number of array dimensions
was unrestricted (in FORTRAN,
at most 3).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 54
Programming Languages
5.
Lower bound of arrays could
be
user-specified.
(in FORTRAN, lower bound=1)
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 55
Programming Languages
6.
Nested selection
statements
were allowed.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 56
Programming Languages
The resulting report described
ALGOL 58, which was used by three
implementation efforts.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 57
Programming Languages
1.
The MAD Language was
implemented at the
University of Michigan.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 58
Programming Languages
2.
NELIAC was introduced by the
U.S. Naval Electronics Group.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 59
Programming Languages
3.
JOVIAL (Jules’ Own Version of the
International Algorithmic Language)
was developed by System Development
Corporation and became the official
scientific language of the U.S. Air Force for
25 years.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 60
Programming Languages
JOVIAL was the only ALGOL 58-
based language that saw
widespread use.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 61
Programming Languages
Other companies, like IBM and SHARE
opted to remain using FORTRAN for
several reasons.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 62
Programming Languages
1.
Developing the first-
generation compilers was hard.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 63
Programming Languages
2.
Training users to use the new
language proved difficult.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 64
Programming Languages
3.
Persuading programmers to
use the new language was
difficult as well.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 65
Programming Languages
In 1959, ALGOL 58 was heavily debated
upon, and the ALGOL Bulletin and
Communications of the ACM both
published suggested modifications for
the language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 66
Programming Languages
The committee met again in 1960 in
Paris and made modifications to
the ALGOL 58 definition.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 67
Programming Languages
1.
Block structure
was introduced.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 68
Programming Languages
2.
The pass-by-value and pass-by-
name parameter passing schemes
were introduced.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 69
Programming Languages
3.
Recursion
was allowed.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 70
Programming Languages
4.
Stack-dynamic arrays
were allowed.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 71
Programming Languages
People of note include Peter Naur,
who published the ALGOL Bulletin
and became heavily involved in the
development of ALGOL.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 72
Programming Languages
Naur used Backus’ Normal
Form (BNF) to formally describe
ALGOL for the 1960 meeting.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 73
Programming Languages
Further improvements were made
in a 1962 meeting held in Rome.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 74
Programming Languages
ALGOL never saw widespread use in the
US (even in Europe, it was not the
dominant language), due to several
problems.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 75
Programming Languages
1.
Some features turned out to be
too flexible,
hampering a complete understanding and
an efficient implementation of the
language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 76
Programming Languages
2.
Lack of
input and output
statements.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 77
Programming Languages
3.
During the time, the use of BNF was
considered strange and complicated
(though today, it is simple and elegant).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 78
Programming Languages
4.
Entrenchment of FORTRAN and
lack of support from IBM.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 79
Programming Languages
Even after the 1962 meeting, ALGOL
had too many ambiguities and
obscurities to be considered fully
complete.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 80
Programming Languages
The programming languages
described so far have been aimed at
scientific computing applications.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 81
Programming Languages
“Mathematical programs should be
written in mathematical notation, data
processing programs should be written
in English statements.”
- Grace Hopper, December 1953
Remington-Rand UNIVAC
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 82
Programming Languages
One of the first programming
languages for business applications
was FLOW-MATIC for UNIVAC, in
1957.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 83
Programming Languages
However, FLOW-MATIC was
designed exclusively for UNIVAC’s
computers.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 84
Programming Languages
IBM also designed COMTRAN
(Commercial Translator).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 85
Programming Languages
First formal meeting for a language
for business applications was held
in the Pentagon, by the
Department of Defense on May
28-29, 1959.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 86
Programming Languages
The language, then called CBL
(Common Business Language)
was to have the following general
characteristics.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 87
Programming Languages
1.
It should use
as much English as
possible.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 88
Programming Languages
2.
Must be easy to use even at the
expense of power.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 89
Programming Languages
3.
Should not be restricted by
implementation problems.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 90
Programming Languages
The COBOL 60 specification was
completed in December 1959 by the
Short Range Committee and
published in April 1960.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 91
Programming Languages
The language was standardized by ANSI
(American National Standards
Institute) in 1968, and it continues to
evolve today (latest standard released
in 2002).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 92
Programming Languages
COBOL introduced a number of
new concepts.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 93
Programming Languages
1.
Hierarchical structures
(which first appeared in Plankalkul’s
design) was first implemented in COBOL.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 94
Programming Languages
2.
First language to allow connotative
variable names with up to 30
characters, including a word-
connecting character (the hypen
‘-’).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 95
Programming Languages
3.
The
DEFINE verb
was the first high-level construct for
macros.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 96
Programming Languages
COBOL’s strongest characteristic
was its Data Division, while the
weakest was its Procedure
Division.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 97
Programming Languages
Every variable is defined in detail in the
Data Division, including the number of
digits, the placement of the decimal
point, etc.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 98
Programming Languages
Main weakness of Procedure Division
was its lack of functions; prior to the
1974 standard, there were no
parameters passed between
subprograms.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 99
Programming Languages
It was the first programming language
mandated for use by the
Department of Defense, which helped
in its eventual widespread use.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 100
Programming Languages
In 1963, John Kemeny and Thomas
Kurtz decided to design a new language
aimed at the liberal arts students of
Dartmouth College.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 101
Programming Languages
The new language had several goals.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 102
Programming Languages
1.
It must be
easy for non-science
students to use.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 103
Programming Languages
2.
It must be
easy and friendly.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 104
Programming Languages
3.
It must provide
fast turnaround
for homework.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 105
Programming Languages
4.
It must allow
free and private access.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 106
Programming Languages
5.
User time must be
considered more than
computer time.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 107
Programming Languages
Goals 2, 3, and 4 led to the
timesharing
aspect of BASIC.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 108
Programming Languages
The first program in timeshared BASIC
was completed on May 1, 1964.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 109
Programming Languages
BASIC was a
very limited language
but was very
easy to learn.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 110
Programming Languages
An executing program could not
get input from the user.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 111
Programming Languages
The original language had 14
different statement types, and a
single-data type (floating-
point).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 112
Programming Languages
It was the first widely-used language
that was
used through terminals
connected to a remote computer.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 113
Programming Languages
All of the programming languages so far
have been used for specific
application areas (scientific
computing, list processing, business
applications, etc.).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 114
Programming Languages
The first large-scale attempt to design a
language for more than one
application area resulted in
PL/I.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 115
Programming Languages
WHY?
An overlap between scientific
computing applications and business
applications was developing.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 116
Programming Languages
Originally named
FORTRAN VI,
its association with FORTRAN was
dropped as it was developed.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 117
Programming Languages
The design of PL/I that was eventually
implemented was published in 1964, and
it was in 1965 that it was officially
called PL/I (before it was the NPL –
New Programming Language).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 118
Programming Languages
Basically, PL/I had the best of what
FORTRAN, ALGOL 60, and COBOL 60
had to offer.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 119
Programming Languages
ALGOL 60’s recursion and block
structure, FORTRAN IV’s separate
compilation with communication
through global data, and COBOL 60’s
data structures, I/O, and report
generating facilities were
incorporated with several new
features.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 120
Programming Languages
1.
Concurrently executing
subprograms
were allowed.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 121
Programming Languages
2.
Exception detection
and
run-time error handling.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 122
Programming Languages
3.
Use of recursion for subprograms
could be disabled to more efficiently
link nonrecursive subprograms.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 123
Programming Languages
4.
Pointers
were included as a data type.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 124
Programming Languages
5.
Cross-sections of arrays
could be referenced.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 125
Programming Languages
Though, PL/I’s constructs for pointers,
exception handling and concurrency
were flawed, it still enjoyed some
success in terms of usage.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 126
Programming Languages
Dynamic typing and dynamic storage
allocation were used in
APL
and
SNOBOL.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 127
Programming Languages
Dynamic Typing – variables are
untyped
Ex. Javascript, etc.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 128
Programming Languages
APL (A Programming Language)
was designed by Kenneth Iverson at
IBM in 1960.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 129
Programming Languages
SNOBOL was designed in the early 1960’s
at Bell Laboratories for text
processing, e.g., string pattern
matching.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 130
Programming Languages
Around 1962-1964,
Kristen Nygaard
and
Ole-Johan Dahl
developed SIMULA I.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 131
Programming Languages
SIMULA I was intended for
simulations.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 132
Programming Languages
It was first implemented in 1964 for
the UNIVAC 1107.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 133
Programming Languages
SIMULA was later extended by both
Nygaard and Dahl resulting in SIMULA 67
in March 1967.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 134
Programming Languages
SIMULA 67 extended ALGOL 60,
using ALGOL’s concepts of block
structure and control
statements, and introduced
coroutines.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 135
Programming Languages
Coroutines – subprograms that can
restart at the position
where they previously
stopped
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 136
Programming Languages
To support coroutines, the
class construct
was developed.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 137
Programming Languages
The development of classes would
eventually give way to data
abstraction, which is the foundation of
object-oriented programming.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 138
Programming Languages
ALGOL saw an update in 1968,
redesigned by van Wijngaarden,
et al, resulting in ALGOL 68.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 139
Programming Languages
ALGOL 68’s redesign had a primary design
criterion:
Orthogonality
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 140
Programming Languages
Orthogonality – small number of
primitive constructs
can be combined in a
small number of ways
to build control and data
structures.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 141
Programming Languages
As a result, ALGOL 68 allowed
user-defined data types.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 142
Programming Languages
Another first for ALGOL 68 was its introduction
of
Implicit-heap dynamic arrays
which will be discussed later.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 143
Programming Languages
ALGOL 68 was never as popular
as PL/I due in large part to IBM’s
support of PL/I.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 144
Programming Languages
Despite never growing in popularity,
ALGOL did have several descendants,
particularly in imperative languages,
some of which may be familiar to you.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 145
Programming Languages
Niklaus Wirth and C. A. R. Hoare
developed ALGOL-W, which was basically
ALGOL 60 with their modifications.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 146
Programming Languages
ALGOL-W was implemented in Stanford
University and was used primarily for
instructional purposes at a few
universities.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 147
Programming Languages
ALGOL-W’s primary contributions were
the
value-result method
for parameter passing and, the
case statement.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 148
Programming Languages
Later, Wirth came up with
Pascal
in 1970.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 149
Programming Languages
Pascal was designed specifically for
instructional purposes.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 150
Programming Languages
By the mid-1970’s, it was the most
widely-used language for its
purpose.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 151
Programming Languages
Pascal’s success it attributed to its
simplicity
and
expressivity.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 152
Programming Languages
Pascal remained popular until the mid-
1990’s when newer languages with more
features began to gain widespread use, like
Ada and C++.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 153
Programming Languages
In 1972, Dennis Ritchie, from Bell
Laboratories, designed and
implemented C.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 154
Programming Languages
C was originally intended for
systems programming.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 155
Programming Languages
C is descended from several
programming languages.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 156
Programming Languages
CPL was developed at Cambridge
University in the early 1960’s.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 157
Programming Languages
BCPL, a simple systems language,
was also developed at Cambridge
by Martin Richards in 1967.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 158
Programming Languages
B was designed and implemented by
Ken Thompson (Bell Laboratories)
under the UNIX system (which was
implemented using assembly).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 159
Programming Languages
C also utilized some constructs
from
ALGOL 68.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 160
Programming Languages
Problem: B and BCPL were both
untyped.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 161
Programming Languages
Thus, Ritchie developed a new
language that was based on B,
called NB. Eventually, Ritchie
renamed it C.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 162
Programming Languages
Problem: C lacked type checking.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 163
Programming Languages
Despite this, C was popular in the
1980’s due to its inclusion in UNIX.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 164
Programming Languages
Prolog was developed in the early
1970’s by
Alain Colmerauer
and
Phillippe Roussel,
and Robert Kowalski.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 165
Programming Languages
Prolog stands for
PROgramming LOGic.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 166
Programming Languages
The concept of Logic Programming
uses formal logic notation to
communicate computational
processes to the computer.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 167
Programming Languages
The formal logic notation used in
Prolog as well as other current
logic programming languages is
Predicate Calculus.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 168
Programming Languages
The inferencing process used in logic
programming languages is called
Resolution,
developed by Robinson in 1965.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 169
Programming Languages
In logic programming, the user provides
relevant information for the inferencing
process using predicate calculus, and
resolution is used to provide the
result.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 170
Programming Languages
Programs in logic programming do not
specify how to compute a result; it just
describes the necessary form
and/or characteristics of the result.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 171
Programming Languages
The first Prolog interpreter was
developed in
1972.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 172
Programming Languages
A common use of Prolog was as an
intelligence database.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 173
Programming Languages
However, until now, logic programming
languages are not widely used for a
couple of reasons.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 174
Programming Languages
1.
Since logic programming is
nonimperative, it is
highly inefficient
compared to imperative languages.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 175
Programming Languages
2.
It is only effective in a
small number of application areas.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 176
Programming Languages
An object-oriented version of
Prolog, called Prolog++, was
developed by Moss in 1994.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 177
Programming Languages
In 1974, the Army, Navy, and Air
Force independently proposed the
development of a single language for
embedded systems.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 178
Programming Languages
Embedded system – computer
hardware is
embedded in a
device that it will
control.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 179
Programming Languages
Problem: Over 450 languages were in
use in the Department of
Defense because each
defense contractor defined
a new language for every
contract.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 180
Programming Languages
As a result, software applications were
rarely reused.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 181
Programming Languages
This problem resulted in the single, most
extensive and expensive language
design effort ever undertaken, eventually
developing the programming language
Ada.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 182
Programming Languages
The process of designing Ada started in
January 1975 when Malcolm Curie,
formed the High-Order Language
Working Group (HOLWG) with
representatives from military services
the UK, France, and Germany.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 183
Programming Languages
HOLWG came up with the
Strawman requirements document
in April 1975. This document was
updated continuously until June
1978, resulting in the Steelman
document.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 184
Programming Languages
Out of all the proposals for the new
language, the Cii Honeywell/Bull
language design proposal was chosen, by
a French group led by Jean Ichbiah.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 185
Programming Languages
Jack Cooper proposed the name
Ada for the language in Spring,
1979.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 186
Programming Languages
The final design and rationale for Ada
was published by ACM, and upon
receiving suggestions for modifications,
the Department of Defense released
the Stoneman document in February,
1980.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 187
Programming Languages
The language design was then updated
and completed in July 1980 in the Ada
Language Reference Manual which
was updated in 1982.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 188
Programming Languages
The final, official design for Ada
was released in 1983 by Goos and
Hartmanis.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 189
Programming Languages
Ada had four major
contributions.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 190
Programming Languages
1.
Packages supported
encapsulation of data,
specifications of data types, and
procedures, providing support for
data abstraction.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 191
Programming Languages
2.
Extensive
exception handling,
where users can gain control when
an exception is encountered.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 192
Programming Languages
3.
Support for
generic program units,
i.e., procedures can be made for an
unspecified data type.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 193
Programming Languages
4.
Concurrent execution of special
program units, using the
rendezvous mechanism.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 194
Programming Languages
Ada embodied the concepts of
software engineering and
language design of the late
1970’s.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 195
Programming Languages
Problem: Development of a compiler
for such a large and complex
language was difficult; the
first truly usable compilers for
Ada appeared in 1985.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 196
Programming Languages
Ada was updated in 1995 (Ada 95)
and 2005 (Ada 2005).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 197
Programming Languages
Ada 95 introduced two new
features.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 198
Programming Languages
1.
Type derivation extended to allow
new components to be added to
those inherited from a base class,
allowing
inheritance.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 199
Programming Languages
2.
Dynamic binding of subprogram
calls to subprogram definitions through
subprogram dispatching based on the
tag value of derived types through
classwide types provided for
polymorphism.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 200
Programming Languages
Ada 95’s popularity suffered partly
because the DoD stopped
requiring it for military software
systems.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 201
Programming Languages
More importantly, C++, which was
released before Ada 95, was gaining
widespread acceptance for object-
oriented programming.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 202
Programming Languages
Ada 2005 added more features, such as
interfaces, synchronized interfaces,
and more control over scheduling
algorithms.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 203
Programming Languages
Ada is still widely used in commercial
and defense avionics, air traffic
control, and rail transportation,
among others.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 204
Programming Languages
The first language to fully support
object-oriented programming is
Smalltalk.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 205
Programming Languages
Alan Kay, employed at the Xerox
Palo Alto Research Center
under the Learning Resource
Group, conceptualized Smalltalk.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 206
Programming Languages
The first release of Smalltalk to the
public was called Smalltalk 80 in
1980.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 207
Programming Languages
In Smalltalk,
everything is an object,
even integer constants.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 208
Programming Languages
Object abstraction is done using
classes similar to those of SIMULA
67.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 209
Programming Languages
Smalltalk syntax is different in its use of
messages
instead of arithmetic and logic expressions,
and conventional control statements.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 210
Programming Languages
Smalltalk’s impact lies in its promotion
of the use of
graphical user interfaces
and
object-oriented programming.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 211
Programming Languages
In 1980, Bjarne Stroustrup at Bell
Laboratories modified C to add type
checking and conversion, and (more
importantly) classes, developing
C with Classes
in 1983.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 212
Programming Languages
C with classes was updated in 1984,
including virtual methods, dynamic
binding of method calls, method
name and operator overloading,
and reference types, and was called
C++.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 213
Programming Languages
C++ has evolved over the years, with
support for several features being
added through different versions.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 214
Programming Languages
nd
The 2 release of C++ added
multiple inheritance
and
abstract classes.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 215
Programming Languages
rd
The 3 release of C++ added
templates
and
exception handling.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 216
Programming Languages
The current version of C++ was
standardized in 1998.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 217
Programming Languages
When Microsoft released the .NET
computing platform in 2002, it
included a new version of C++, called
Managed C++.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 218
Programming Languages
Unlike standard C++, Managed C++ does
not support multiple inheritance
because .NET does not support it.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 219
Programming Languages
C++ supports both procedural and
object-oriented programming due
to its support for both functions and
methods.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 220
Programming Languages
C++ remains popular today due to
several factors.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 221
Programming Languages
1.
Good and inexpensive
compilers
are available.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 222
Programming Languages
2.
Backward compatibility
with C.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 223
Programming Languages
3.
It was the only suitable object-
oriented programming language
for large commercial projects at the
time.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 224
Programming Languages
Problem: C++ is very large and
complex, has similar
drawbacks as PL/I, and
inherited C’s insecurities.
Ada and Java are much safer
languages.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 225
Programming Languages
Some related languages to C++ are
Objective-C,
Delphi,
and Go.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 226
Programming Languages
Objective-C was designed by
Brad Cox and Tom Love and
first appeared in 1983.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 227
Programming Languages
Objective-C basically
added Smalltalk messaging
to C.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 228
Programming Languages
Objective-C is the main
programming language for the OSX
and iOS operating systems by
Apple.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 229
Programming Languages
Like C++, Objective-C has all
of C’s insecurities.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 230
Programming Languages
Delphi was created by adding
object-oriented support to
Pascal.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 231
Programming Languages
Delphi was designed by Anders
Hejlsberg, who also became the
lead designer of C#.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 232
Programming Languages
Since Pascal is less complex, more
elegant, and safer than C, the same
goes for Delphi relative to C++.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 233
Programming Languages
Go, designed by Rob Pike, Ken
Thompson, and Robert Grisemer at
Google was developed from 2007 until
its release in late 2009.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 234
Programming Languages
Development was prompted by the
slowness of the compilation of
large C++ programs in Google.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 235
Programming Languages
As a result, the compiler for Go is
extremely fast.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 236
Programming Languages
Problem: C and C++, due to
aforementioned insecurities,
were considered unreliable
for embedded systems for
consumer electronics.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 237
Programming Languages
In 1990, Sun Microsystems
determined a need for a programming
language for embedded systems on
consumer electronics.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 238
Programming Languages
The resulting language, by a design
team led by James Gosling, was
Java,
and it was based on C++.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 239
Programming Languages
Though Java was intended for embedded
systems, when it was released in 1995,
it became widely used in Web
programming with the advent of
graphical web browsers.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 240
Programming Languages
Main Reason: Java Applets
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 241
Programming Languages
Although based on C++, Java
smaller,
simpler,
and more reliable.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 242
Programming Languages
Java has several features that are
different from those of C++.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 243
Programming Languages
1.
Predefined classes
for arrays.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 244
Programming Languages
2.
No pointers,
but its reference types allow some
capabilities of pointers.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 245
Programming Languages
3.
Stand-alone programs are not
possible in Java since all
subprograms are methods
defined under a class.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 246
Programming Languages
4.
Java only supports single
inheritance, but simulates some
benefits of multiple inheritance
using
interfaces.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 247
Programming Languages
5.
Java does not have
structs and
unions.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 248
Programming Languages
6.
Implicit storage deallocation,
a.k.a. garbage collection, frees
programmers from deleting objects
explicitly.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 249
Programming Languages
7.
Implicit type conversions are only
allowed if they are widening, i.e., int to
float conversion is allowed, float to in
conversion is not.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 250
Programming Languages
Java also supports concurrency using
threads, and the synchronized
modifier for methods and blocks.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 251
Programming Languages
The price of Java’s portability has
always been the cost of
interpretation, and for a time, Java
programs were 10 times slower than
equivalent C programs.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 252
Programming Languages
Just-in-Time (JIT) compilers are now
being used to compile Java code to
machine code before execution making
them competitive with other compiled
languages.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 253
Programming Languages
The use of Java increased
faster than any other
programming language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 254
Programming Languages
Microsoft eventually developed
their own spin-off of C++, which
they called
C#.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 255
Programming Languages
C# was released in January 2002
along with the .NET development
platform.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 256
Programming Languages
Aside from C++, C# also takes
some concepts from Delphi and
Visual BASIC.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 257
Programming Languages
The lead designer of C#,
Anders Hejlsberg,
also designed Turbo Pascal and
Delphi.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 258
Programming Languages
Purpose of C#: Component-based
software
development.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 259
Programming Languages
All languages under the .NET framework
use the Common Type System (CTS),
utilizing a common class library.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 260
Programming Languages
All types that in all five languages inherit
from
[Link],
much like [Link] in
Java.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 261
Programming Languages
C# utilized C++ concepts that
Java removed, except for
multiple inheritance.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 262
Programming Languages
However, although some viewed this
inclusion of C++ features as a backward
step, C# designers did improve on
most C++ features that they included.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 263
Programming Languages
C# also has some features that
are different from Java.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 264
Programming Languages
1.
Conversion between primitive
and object types is partially
implicit.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 265
Programming Languages
2.
Rectangular arrays
are supported.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 266
Programming Languages
3.
A foreach statement, similar to
that of Perl, PHP, and Java 5.0
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 267
Programming Languages
Scripting
Languages
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 268
Programming Languages
Scripting languages have been
developing for the last 25 years.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 269
Programming Languages
At first, scripting languages were made
up of a small collection of commands
interpreted as calls for system
subprograms for utility functions, file
management, and simple file
filtering.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 270
Programming Languages
Eventually, variables, control
flow statements, functions, and
other capabilities were added,
resulting in programming languages.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 271
Programming Languages
The first scripting language was
sh (for shell).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 272
Programming Languages
The most powerful and widely used is
ksh,
developed by David Korn at Bell
Laboratories.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 273
Programming Languages
A handful of scripting programming
languages developed over time.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 274
Programming Languages
Perl was developed by
Larry Wall
as a combination of sh and awk.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 275
Programming Languages
Although Perl is still considered a
scripting language, it is actually
more similar to imperative
languages.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 276
Programming Languages
Javascript
was developed by Brendan Eich
at Netscape.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 277
Programming Languages
Javascript was developed due to a need
for
computations with HTML documents
at the client side.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 278
Programming Languages
One of its major uses is for
dynamically creating and
modifying HTML documents using
the
Document Object Model (DOM).
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 279
Programming Languages
PHP was developed by
Rasmus Lerdorf
of the Apache group in 1994.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 280
Programming Languages
Originally PHP stood for
Personal Home Page,
but it now stands for PHP:
Hypertext Preprocessor.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 281
Programming Languages
PHP is an HTML-embedded
server-side scripting language
for Web applications.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 282
Programming Languages
Though initially without support for
object-oriented programming, the
current versions of PHP have
object-oriented concepts.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 283
Programming Languages
Python was initially designed by
Guido van Rossum
at Stichting Mathematisch Centrum
in the early 1990’s.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 284
Programming Languages
Python is used for similar
purposes as Perl.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 285
Programming Languages
One of its most interesting features
is
extensibility.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 286
Programming Languages
Ruby, developed by
Yukihiro Matsumoto,
was released in 1996.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 287
Programming Languages
Ruby was developed because although
Perl and Python had support for OOP,
neither of them was a pure object-
oriented programming language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 288
Programming Languages
Ruby is a pure object-oriented
language, much like Smalltalk.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 289
Programming Languages
It is also the first programming
language that was developed in
Japan and is now widely used in
the United States.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 290
Programming Languages
Lua, designed in the early 1990’s by
Roberto Ierusalimschy, et al, at the
Pontifical University of Rio de
Janeiro in Brazil is a procedural and
functional scripting language.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 291
Programming Languages
Lua’s design was influenced by
Scheme, Icon and Python.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 292
Programming Languages
The rise in the use of Lua is thanks
to the gaming industry starting
in 2006-2007.
CMSC 124 - Design and Implementation of
1st Semester AY 2013-2014 293
Programming Languages