CS 403: a Brief (And Pretty Incomplete) History of Programming Languages (S

CS 403: a Brief (And Pretty Incomplete) History of Programming Languages (S

HISTORY OF PROGRAMMING LANGUAGES CS 403: A Brief (and Pretty Incomplete) History of “Prehistory” Programming Languages The 1940s: von Neumann and Zuse The 1950s: The first programming language The 1960s: An explosion in programming languages Stefan D. Bruda The 1970s: Simplicity, abstraction, study The 1980s: Consolidation and new directions The 1990s: The explosion of the World Wide Web Fall 2021 The 21st century CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 1 / 21 PREHYSTORY WRITTEN LANGUAGE TO DESCRIBE COMPUTATIONAL PROCEDURES Cuneiform writing used in the Babylon, founded by Hammurabi around 1790 BC A cistern. poems, stories, contracts, records, astronomy, math The length equals the height. A certain volume of dirt has been excavated. The cross-sectional area plus this volume comes to 110. The length is 30. What is the width? Famous Babylonian math You should multiply the length, 30, by . tablet (Plimpton 322) — Translation by Donald Knuth involving Pythagorean triples, a2 + b2 = c2 – with No variables a mistake! (or bug) Instead, numbers serve as a running example of the procedure being described “This is the procedure” Weird math (base 60!) Programming is among the earliest uses to which written language was two characters to express a (base-60) digit put decimal point not specified (must be figured out from context) Programming languages design has tried to get as close to that as possible from the very beginning. CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 2 / 21 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 3 / 21 ALGORITHMS THE FIRST PROGRAMMING ENVIRONMENTS Abu¯ ’Abdallah¯ Muh. ammad ibn Mus¯ a¯ al-Khwarizm¯ ¯ı, or Mohammed Al-Khorezmi for short (Baghdad, 780–850 BC) Jacquard loom (early 1800s) translated One little book: “The Compendious Book on Calculation by Completion and card patterns into cloth designs Balancing” Compilation and extension of known rules for solving quadratic equations and Charles Babbage’s Analytical Engine other problems (1830s & 40s) Used as a mathematics text in Europe for eight hundred years First programmer: Augusta Ada King, The book is considered the foundation of algebra Countess of Lovelace (today commonly Invention of the notions of algorithms and data structures known as Ada Lovelace) Other early algorithms: The engine can arrange and combine its numerical quantities exactly as if they Euclid (300 BC): an algorithm for computing the GCD of two numbers were letters or any other general symbols; Eratosthenes (about same time): one of the most efficient algorithms for and in fact might bring out its results in al- finding small primes (the sieve of Eratosthenes) gebraic notation, were provision made. Alexander de Villa Dei (1220 AD): Canto de Algorismo = algorithms in Latin verse Programs were punched cards containing data and operations Natural language (even poetry!) plus math rather than programming languages CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 4 / 21 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 5 / 21 THE 1940S: VON NEUMANN AND ZUSE THE FIRST COMPUTER BUG! Harvard Mark I (1943) – Howard Aiken (IBM), Grace Hopper (Navy) first electro-mechanical computer → Harvard Mark II: First computer bug ENIAC (1946) – Presper Eckert, John Mauchly (U. Penn.) First → electronic computer Programming was manual, with switches and cables John von Neumann led a team that built computers with stored programs and a central processor (as we know them today) Konrad Zuse designed the first programming language as we know it (Plankalkul = program calculus) In Germany, in isolation because of the war; work finally published in 1972 Advanced data type features: floating point, arrays, records Invariants for correctness Rather cumbersome notation 5 B A ∗ ⇒ A[7] := 5 B[6] V 6 7 (subscripts) × → S 1.n 1.n (data types) Never implemented CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 6 / 21 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 7 / 21 THE 1950S:THE FIRST PROGRAMMING LANGUAGES FORTRAN EXAMPLE FORTRAN (1957, John Backus) IMPLICIT INTEGER (A-Z) FORmula TRANslator – designed for scientific programming DIMENSION ORD(N),POPLST(2,20) Many new features over time: FORTRAN II, FORTRAN IV, FORTRAN 66, INTEGER X,XX,Z,ZZ,Y FORTRAN 77 (structured programs, char’s), Fortran 90 (arrays, modules), INTEGER A(N) Fortran 2003 (objects), Fortran 2008 (concurrent programming) NDEEP=0 Very efficient compilation into fast machine code U1=N COBOL (1960, Grace Hopper) L1=1 mathematical programs should be written in mathematical notation, DO 1 I=1,N data processing programs should be written in English statements — 1 ORD(I)=I G. Hopper, 1953 2 IF (U1.LE.L1) RETURN 3 L=L1 Committee sponsored by US Department of Defence U=U1 Biggest contribution was the idea that programs should be written in a way 4 P=L that is easily understood Q=U Adopted widely by businesses for record-keeping applications Record structure, separation of data from execution part, versatile formatting X=A(ORD(P)) of output using “pictures” Z=A(ORD(Q)) ANSI standards (1968, 1974, 1985) IF (X.LE.Z) GO TO 5 .... 5 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 8 / 21 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 9 / 21 COBOL EXAMPLE THE 1950S:THE FIRST LANGUAGES (CONT’D) ENVIRONMENT DIVISION. CONFIGURATION SECTION. Algol 60 SOURCE-COMPUTER. IBM-4381. General, expressive language; most current imperatives are derivatives OBJECT-COMPUTER. IBM-4381. Introduced many modern concepts structured programming reserved keywords type declarations DATA DIVISION. recursion stack dynamic arrays call-by-value WORKING-STORAGE SECTION. user defined types free-format 01 INPUT-FIELD. Stack-based run time environment 05 INPUT-VALUE PIC 99 VALUE ZERO. Great success and also great failure (ahead of its time, too complex, lack of 01 CALCULATION-FIELD. I/O, lack of support from IBM) entrenchment of Fortran → 05 SUM-VALUE PIC 9(03) VALUE ZERO. LISP (John McCarthy, MIT) 05 AVERAGE-VALUE PIC 9(03)V99 VALUE ZERO. LISt Processing the main data structure is the (singly linked) list 01 OUTPUT-FIELD. → Untyped, messy language, but good for problems we solve by trial and error 05 EDIT-FIELD PIC ZZ9.99 VALUE ZERO. (quick prototyping) used in many AI applications → Historically inefficient on Von Neumann machines PROCEDURE DIVISION. Main processing unit: the recursive function influenced the modern 1000-MAIN. → functional languages such as ML, Miranda, Haskell PERFORM 2000-INPUT-ADD 10 TIMES. Contemporary variants include Common Lisp, Scheme, Emacs Lisp DIVIDE 10 INTO SUM-VALUE GIVING AVERAGE-VALUE. 2000-INPUT-ADD. ... CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 10 / 21 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 11 / 21 ALGOL EXAMPLE LISP EXAMPLE procedure Absmax(a) Size:(n, m) Result:(y) Subscripts:(i, k); value n, m; (defun mapcar (fun list) array a; "Applies FUN on every element of LIST and returns the integer n, m, i, k; list of results (iterative version)." real y; (let ((results nil)) comment The absolute greatest element of the matrix a, of size (dolist (x list) n by m is transferred to y, and the subscripts of this element (setq results (cons (apply #’fun x) results))) to i and k; (reverse results))) begin integer p, q; y := 0; i := k := 1; (defun mapcar (fun list) for p:=1 step 1 until n do "Applies FUN on every element of LIST and returns the for q:=1 step 1 until m do list of results (recursive version)." if abs(a[p, q]) > y then (cons (apply #’fun (car list)) begin y := abs(a[p, q]); (mapcar fun (cdr list)))) i := p; k := q end end Absmax CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 12 / 21 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 13 / 21 THE 1960S:AN EXPLOSION IN LANGUAGES THE 1970S:SIMPLICITY, ABSTRACTION, STUDY Hundreds of languages were developed Algol-W then Pascal (Nicklaus Wirth and C.A.R.Hoare) small, simple, → efficient (reaction against the 60s), ideal for teaching C (Dennis Ritchie) PL/1 (1964) Constructed as a portable assembler to build Unix for various architectures Combined features of FORTRAN, COBOL, Algol 60 and more! But also has modern features (structured programming, data structures, etc.) Translators were slow, huge, and unreliable The primary API for Unix (Mac OS, Linux, etc.) is still C! Some say it was ahead of its time. Euclid (University of Toronto, 1977) Algol 68 still ahead of its time! Main goal formal program verification → → Simula (or what would be called today Object-oriented Algol) extends Pascal to include abstract data types BASIC Scheme (1978, MIT) simplified, cleaner Lisp → etc. CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 14 / 21 CS 403: A Brief (and Pretty Incomplete) History of Programming Languages (S. D. Bruda) Fall 2021 15 / 21 C EXAMPLE THE 1980S:CONSOLIDATION & NEW DIRECTIONS #include <stdio.h> main(t,_,a) char*a; {return!0<t?t<3? main(-79,-13,a+ main(-87,1-_, main(-86, 0, a+1 ) +a)): ML mostly functional language (like Lisp) with cleaner (math-like) 1, → t<_? syntax main(t+1, _, a ) :3, Prolog (Universite´ Aix Marseille) main ( -94, -27+t, a ) &&t == 2 ?_ PROgrammation en LOGique / PROgramming in LOGic describes the <13 ? → main ( 2, _+1, "%s %d %d\n" ) problem at hand as known facts and inference rules :9:16: t<0? Notable industrial uses: IBM Watson, Apache UIMA, and the.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    6 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us