Programming Languages CMSC 4023 Chapter 2

Size: px
Start display at page:

Download "Programming Languages CMSC 4023 Chapter 2"

Transcription

1 2. Programming languages are designed to satisfy two objectives People need to be able to write instructions that implement computational procedures and algorithms in a programming language Programming languages need to express mathematical concepts and mathematical notation. The development of programming languages has been influenced by the development of the electronic hardware that executes computer programs. Some developers of programming languages have attempted to define a language that can be used to define an algorithm without exactly specifying the sequence of instructions for the algorithm Early : The First Programmer John von Neumann ( ) Before the advent of John von Neumann results were computed using telephone switchboard machinery. If one desired a different computation, one rearranged the switchboard. John von Neumann conceived the idea that instructions and data should be stored in memory. A central processing unit should execute instructions fetched from memory. Thus the von Neumann bottleneck was born. Execution was limited by the pathway from memory to the CPU. Instructions could not be executed any faster than they could be fetched from memory. Figure 1. Von Neumann Architecture Charles Babbage and Ada Lovelace ( ) Charles Babbage conceived the idea of a difference engine implemented entirely using mechanical parts. He failed in his goal because sufficiently accurate machining was not available in his era. However, the concept was proven by the London Science Museum. 1

2 Based on Babbage's original plans, the London Science Museum constructed a working Difference Engine No. 2 from 1989 to 1991, under Doron Swade, the then Curator of Computing. Ada Lovelace developed algorithms for the difference engine and, later, for the analytical engine. It is clear from her notes that she understood both the concept of programs and the essential symbolic nature of programs. Figure 2. The Difference Engine constructed by the London Science Museum 2.2. The 1950s: The First Programming Languages Machine language Machine language is the language accepted by the central processing unit (CPU) or, in the example below, a virtual machine interpreter. It consists entirely of 0s and 1s opcode operand 1 operand Figure 3. Anatomy of a P-Code Instruction iaddr P-Code Operand 1 Operand 2 Comment Start procedure addlocal Allocate storage for variable i and the stack mark Reserve 3 elements for the computation stack Load the address of variable i in preparation to store a value. 3 2F Load the value of variable i 4 2A Load an integer constant B Add the two integers on top of the stack Assign the sum to variable i Return to the caller Start program locals Allocate storage for the stack mark 2

3 Reserve 5 elements for the computation stack Figure 3. Annotated Machine P-Code listing of program locals iaddr P-Code Operand 1 Operand 2 Comment A Allocate storage for procedure addlocals stack mark B Call procedure addlocal. C Return to the caller D Execution starts here. Create program main's stack mark. D Call program local F Stop Figure 3. Annotated Machine P-Code listing of program locals Assembly language Assembly language is a symbolic form of machine language. Mnemonics are assigned to operations, registers, and other values. Variables are referenced by their relative address. iaddr P-Code Operand 1 Operand 2 Comment 0 ent sp 5 Start procedure addlocal Allocate storage for variable i and the stack mark 1 ent ep 3 Reserve 3 elements for the computation stack 2 lda 0 5 Load the address of variable i in preparation to store a value. 3 lvi 0 5 Load the value of variable i 4 ldc i 1 Load an integer constant 1. 5 adi Add the two integers on top of the stack. 6 sti i Assign the sum to variable i. 7 rtn p Return to the caller 8 ent sp 4 Start program locals Allocate storage for the stack mark 9 ent ep 5 Reserve 5 elements for the computation stack A mst 0 Allocate storage for procedure addlocals stack mark B cup 0 0 Call procedure addlocal. C rtn p Return to the caller D mst 0 Execution starts here. Create program main's stack mark. D cup 0 8 Call program local F stp Stop Figure 4. Annotated Assembly P-Code listing of program locals 3

4 program locals; procedure addlocal; var i:integer; begin{addlocal} i:=i+1 end{addlocal}; begin{locals} addlocal end{locals}. Figure 5. Program local FORTRAN First High Level Programming Language FORTRAN FORmula TRANslation John Backus Scientific and computational programming Efficiency Storage allocation is not stack-based but statically allocated by the compiler for efficiency. FORTRAN II, FORTRAN IV, FORTRAN66, FORTRAN77, FORTRAN90 ******ERRORS INDUCED BY ARITHMETIC OPERATONS ON SAMLL NUMBERS REAL SUM6,SUM7,SUM8,DIF6,DIF7,DIF8,SUMINF * OPEN(6,FILE='PRN') SUM6=.9*(1.-0.1**6)/0.9 SUM7=.9*(1.-0.1**7)/0.9 SUM8=.9*(1.-0.1**8)/0.9 ******COMPUTER SUM OF INFINITE TERMS SUMINF=0.9/( ) ******COMPUTE DIFFERENCES BETWEEN FINITE & INFINITE SUMS DIF6 = SUMINF - SUM6 DIF7 = SUMINF - SUM7 DIF8 = SUMINF - SUM8 WRITE(6,*) 'INFINITE SUM = ', SUMINF WRITE(6,*) 'SUM6 = ', SUM6, ' INFINITE SUM - SUM6 = ', DIF6 WRITE(6,*) 'SUM7 = ', SUM7, ' INFINITE SUM - SUM7 = ', DIF7 WRITE(6,*) 'SUM8 = ', SUM8, ' INFINITE SUM - SUM8 = ', DIF8 STOP END Figure 6. A Fortran program 4

5 COBOL COmmon Business-Oriented Language U. S. Department of Defense ( ) and Admiral Grace Hopper Large-scale record-keeping and other business applications A goal of the language designers was for coded programs to be easily read and understood (a failure). Business schools often offer courses on COBOL programming, but computer science departments generally do not.) The language is extremely wordy Sophisticated algorithms are difficult to program in COBOL Innovations include the record structure and separation of data declarations from executable portions of the program "The use of COBOL cripples the mind; its teaching should, therefore, be regarded as a criminal offense" - Edsger Dijkstra 1975 IDENTIFICATION DIVISION. Program-Id. Hello-World. * ENVIRONMENT DIVISION. * DATA DIVISION. * PROCEDURE DIVISION. Para1. DISPLAY "Hello, world.". * Stop Run. Figure 7. A COBOL Program ALGOL60 Developed by an international Committee chaired by W. L. van der Poel including John Backus, Edsger Dijkstra, Peter Naur, and A. van Wijngaarden An Historic Event Grammar Backus Naur Form (BNF) Descendents include Pascal, C, Modula-2, and Ada Introduced many concepts including o free-format o structured statements o begin-end blocks o type declarations o recursion o pass by-value parameters o stack-based runtime environment for block-structured languages 5

6 begin integer i, n, b, c; real t, p, q, m, s; n:= read; c:=0; p:=0; q:=0; for i:=1 step 1 until n do begin t:=read; b:=read; p:=p+t; q:=q+t^2; if t>=7 and b>=1 then c:=c+1 end; m:=p/n; s:=sqrt(q/n-m^2); print(c); print(m); print(s) end Figure 8. An Algol Program LISP Developed at MIT in the late 1950s by John McCarthy Functional programming Artificial intelligence Variants include MacLisp, Franz Lisp, Common LISP, and Scheme Based on a uniform data structure, the S-expression Introduced garbage collection Conceptually different than the von Neumann architecture and inherently inefficient. Special purpose architectures have been developed to execute Lisp programs Recursion (defun factorial (n) (if (<= n 1) 1 (* n (factorial (- n 1))))) Figure 9. A Lisp Function 6

7 APL A Programming Language Ken Iverson at Harvard IBM in the late 1950s and early 1960s A language for programming mathematical computations, particularly those involving arrays and matrices APL included a large number of operators that allow most iterations to be performed completely automatically. Drawbacks include no structuring, and its use of the Greek alphabet. APL was extremely difficult to read Special IBM character set keyboard The following program finds all prime numbers from 1 to R (presuming an index origin of 1). In both time and space, the calculation is O(R 2 ). From right to left, this means: 1. creates a vector containing integers from 1 to R (if R = 6 at the beginning of the program, is ) 2. Drop first element of this vector ( function), i.e. 1. So is Set R to the vector (, assignment primitive) 4. Generate outer product of R multiplied by R, i.e. a matrix which is the multiplication table of R by R ( function) 5. Build a vector the same length as R with 1 in each place where the corresponding number in R is in the outer product matrix (, set inclusion function), i.e Logically negate the values in the vector (change zeros to ones and ones to zeros) (, negation function), i.e Select the items in R for which the corresponding element is 1 ( function), i.e The 1960s: An Explosion in Programming Languages Special-purpose languages Special-purpose languages for graphics, communications, report generation, etc. Jean Sammett PL/I A language to end all languages everything for everybody IBM A combination of FORTRAN, COBOL, and Algol60. concurrency exceptional handling Vienna Design Language (VDL) General Motors First failed example of a corporation that tried to make money from a programming language 7

8 Algol A more expressive and theoretically completely consistent structure. Features o general type system o expression orientation without arbitrary restrictions o completely orthogonal language SNOBOL StriNg Oriented symbolic Language R. Griswold at Bell Labs early 1960s String processing language Sophisticated and powerful pattern matching facilities Simula67 Created by Kristen Nygaard and OleJohan Dahl at the Norwegian Computing Center during the period Designed originally for simulations Introduced the class concept First object-oriented language BASIC Beginners All-purpose Symbolic Instruction Code Designed in 1964 by John Kemeny and Thomas Kurtz at Dartmouth College A simple programming language for time-sharing systems Introduced contextual type declarations 2.4. The 1970s: Simplicity, Abstraction, Study Algol-W (Niklaus Wirth & C. A. R Hoare) A response to the complexity of Algol68 Simplicity and consistency Pascal (Niklaus Wirth 1971) Refined and distilled the simplicity and consistency drafted in Algol-W Purpose: teaching programming Highly successful Omitted o separate compilation o adequate string handling o expandable input-output C (Dennis Ritchie, 1972, Bell Labs) Goal: simplicity retaining and restricting the expression orientation reducing the complexity of the type system reducing the complexity of t he run-time system Success of C is due in part to the Unix operating system that is implemented in C CLU (Barbara Liskov, , MIT) Goal: a consistent approach to abstraction mechanisms including o data abstraction o control abstraction o exception handling cluster: a mechanism similar to the class construct in Simula iterator: very general control construct Euclid (University of Toronto, ) Goal: formal verification of programs 8

9 Mesa (Xerox Palo Alto Research Center, ) Pascal-like but with the following additions o modules o exception handling o concurrency o parallel programming 2.5. The 1980s: New Directions and the Rise of Object-Orientation Procedural languages Ada (Jean Ichbiah, designed 1980, accepted 1983) o Goal: common language to implement Department of Defense embedded computer programs o Features included Pascal base package: abstract data type mechanism task: concurrency or parallel programming exception handling o Large and complex in the advent of the PC revolution o Initially no object-oriented features o Required a large infrastructure that did not exist Modula-2 (Niklaus Wirth, 1985, 1988) Pascal successor Goal: construct operating systems module: a mechanism similar but more restricted than an Ada package. coroutine: concurrency suitable for systems programming on a singleprocessor system limited support for Abstract Data Types (ADTs) restrictive type system Ada and Modula-2 are dominated by the thought that a strongly typed language will reduce the amount of time in testing because most of the errors will be discovered in compilation as a result of type mismatches Object-oriented languages Smalltalk (Alan Kay, Dan Ingalls, Xerox Palo Alto Research Center, ) Purest example of an object-oriented language Developed in conjunction with a personal computer, windowing system, mouse, a graphical user interface and the Ethernet C++ (Bjarne Stroustrup, Bell Labs, ) Originally C with classes efficient added inheritance, polymorphism, templates, and operator overloading added libraries ported to nearly every platform An ISO standard was established in 1998 (Almost no compiler completely complies with the standard) Object-oriented languages attempt to solve the costly problem of testing by use of inheritance and layering. Once a layer has been tested it remains totally unchanged retaining the value of its tests. Creating a new program amounts to selecting the beginning layer and adding to that. Modifying a working layer invalidates the tests Functional programming languages Scheme, ML, and Common Lisp Scheme, a more uniform Lisp developed from by Gerald J. Sussman and Guy L. Steele, Jr. at MIT 9

10 o resembles the Lambda Calculus ML and Miranda ML (Metalanguage) Robin Milner at Edinburgh University beginning in Syntax related to Pascal more flexible and powerful Prolog (A. Colmerauer, Marseille beginning in 1972) Logic programming Based on first-order predicate calculus 2.6. The 1990s: Consolidation, the Internet, Libraries, and Scripting Object-oriented programming languages Java Developed by James Gosling at Sun Microsystems in 1995 Goal: a programming language designed to implement embedded consumer-electronic applications Most often Interpreted making it easy to port Used to implement many internet-related applications Owned by Sun Microsystem and, therefore, unlikely to have an ISO or ANSI standard Widely used in universities Functional programming languages Haskell Purely functional language similar to ML and Miranda Libraries Historically, a secondary importance API (Application Programming Interface) introduced in Java Scripting languages AWK, Perl, Tcl, Javascript, Rexx, Python Definition: A scripting language is a language that ties together utilities, library components and operating system commands into complete programs. programs are often short, for example in AWK {print NR, $0} Prints any text file wit h line numbers or Tcl/Tk button.b text Hello! font {Times 16} command {puts hello} Creates a button on the screen labeled Hello! and when pressed prints the message hello to the standard output Visual Basic 2.7. The Future Escape the detailed specification of the sequence of actions that accomplish an objective. 10

Language Translation, History. CS152. Chris Pollett. Sep. 3, 2008.

Language Translation, History. CS152. Chris Pollett. Sep. 3, 2008. Language Translation, History. CS152. Chris Pollett. Sep. 3, 2008. Outline. Language Definition, Translation. History of Programming Languages. Language Definition. There are several different ways one

More information

Chapter 2. 5 * B => A V 6 7 (subscripts) S 1.n 1.n (data types)

Chapter 2. 5 * B => A V 6 7 (subscripts) S 1.n 1.n (data types) 1. Plankalkül - 1945 - Never implemented - Advanced data structures - floating point, arrays, records - Invariants - Notation: A(7) := 5 * B(6) 5 * B => A V 6 7 (subscripts) S 1.n 1.n (data types) 2. Pseudocodes

More information

Introduction. A. Bellaachia Page: 1

Introduction. A. Bellaachia Page: 1 Introduction 1. Objectives... 2 2. Why are there so many programming languages?... 2 3. What makes a language successful?... 2 4. Programming Domains... 3 5. Language and Computer Architecture... 4 6.

More information

2. Evolution of the Major Programming languages

2. Evolution of the Major Programming languages 2. Evolution of the Major Programming languages Genealogy of Common Programming Lang. 2.1 Plankalkül - 1945 Never implemented Advanced data structures floating point, arrays, records Invariants Notation:

More information

Lecture 09. Ada to Software Engineering. Mr. Mubashir Ali Lecturer (Dept. of Computer Science)

Lecture 09. Ada to Software Engineering. Mr. Mubashir Ali Lecturer (Dept. of Computer Science) Lecture 09 Ada to Software Engineering Mr. Mubashir Ali Lecturer (Dept. of dr.mubashirali1@gmail.com 1 Summary of Previous Lecture 1. ALGOL 68 2. COBOL 60 3. PL/1 4. BASIC 5. Early Dynamic Languages 6.

More information

Programming Languages, Summary CSC419; Odelia Schwartz

Programming Languages, Summary CSC419; Odelia Schwartz Programming Languages, Summary CSC419; Odelia Schwartz Chapter 1 Topics Reasons for Studying Concepts of Programming Languages Programming Domains Language Evaluation Criteria Influences on Language Design

More information

CSCI.4430/6969 Programming Languages Lecture Notes

CSCI.4430/6969 Programming Languages Lecture Notes CSCI.4430/6969 Programming Languages Lecture Notes August 28, 2006 1 Brief History of Programming Languages Ada Augusta, the Countess of Lovelace, the daughter of the poet Lord Byron, is attributed as

More information

Chapter 2. Pseudocodes: Speedcoding. 2.2 Minimal Hardware Programming: Pseudocodes. Evolution of the Major Programming Languages

Chapter 2. Pseudocodes: Speedcoding. 2.2 Minimal Hardware Programming: Pseudocodes. Evolution of the Major Programming Languages Chapter 2 Evolution of the Major Programming Languages ISBN 0-321-33025-0 2.2 Minimal Hardware Programming: Pseudocodes What was wrong with using machine code? Poor readability Poor modifiability Expression

More information

Software II: Principles of Programming Languages

Software II: Principles of Programming Languages Software II: Principles of Programming Languages Lecture 2 A History of Programming Languages What is a Programming Language? A programming language describes computation to be performed by computers.

More information

Chapter 2. Evolution of the Major Programming Languages

Chapter 2. Evolution of the Major Programming Languages Chapter 2 Evolution of the Major Programming Languages Chapter 2 Topics Zuse s Plankalkül Minimal Hardware Programming: Pseudocodes The IBM 704 and Fortran Functional Programming: Lisp The First Step Toward

More information

CS508-Modern Programming Solved MCQ(S) From Midterm Papers (1 TO 22 Lectures) BY Arslan

CS508-Modern Programming Solved MCQ(S) From Midterm Papers (1 TO 22 Lectures) BY Arslan CS508-Modern Programming Solved MCQ(S) From Midterm Papers (1 TO 22 Lectures) BY Arslan April 18,2017 V-U For Updated Files Visit Our Site : Www.VirtualUstaad.blogspot.com Updated. MidTerm Papers Solved

More information

History of Programming Languages

History of Programming Languages History of Programming Languages History Early History : The first programmers 1940s: Von Neumann and Zuse 1950s: The First Programming Language 1960s: Explosion in Programming languages 1970s: Simplicity,

More information

Chapter 2. Chapter 2

Chapter 2. Chapter 2 1. Plankalkül 1945(program calculus) pp. - 41 - Never implemented but based on Z4 - Advanced data structures(scalar type and for loop) - integer, floating point, arrays, records - Mathematical expression,

More information

Chapter 2. Evolution of the Major Programming Languages

Chapter 2. Evolution of the Major Programming Languages Chapter 2 Evolution of the Major Programming Languages Chapter 2 Topics Zuse s Plankalkül Minimal Hardware Programming: Pseudocodes The IBM 704 and Fortran Functional Programming: Lisp The First Step Toward

More information

Comp 333: Concepts of Programming Languages Fall 2016

Comp 333: Concepts of Programming Languages Fall 2016 Comp 333: Concepts of Programming Languages Fall 2016 Instructor: Professor Schwartz History Syntax and Semantics Compilers Language Constructs Names, Binding, Scoping, Data Types Expressions, Control

More information

Chapter 2. Evolution of the Major Programming Languages ISBN

Chapter 2. Evolution of the Major Programming Languages ISBN Chapter 2 Evolution of the Major Programming Languages ISBN 0-321-33025-0 Chapter 2 Topics Zuse s Plankalkul Minimal Hardware Programming: Pseudocodes The IBM 704 and Fortran Functional Programming: LISP

More information

Chapter 2. Evolution of the Major Programming Languages ISBN

Chapter 2. Evolution of the Major Programming Languages ISBN Chapter 2 Evolution of the Major Programming Languages ISBN 0-321-49362-1 Chapter 2 Topics Zuse s Plankalkül Minimal Hardware Programming: Pseudocodes The IBM 704 and Fortran Functional Programming: Lisp

More information

Lecture 2. A Historical View

Lecture 2. A Historical View Lecture 2 A Historical View Hardware Programming Short Code (John Mauchly, 1949) for UNIVAC I; two-six-bit byte instructions; implemented as a pure interpreter FORTRAN Previous all floating point calculations

More information

Chapter 2 Evolution of the Major Programming Languages Chapter 2 Topics

Chapter 2 Evolution of the Major Programming Languages Chapter 2 Topics Chapter 2 Evolution of the Major Programming Languages Chapter 2 Topics Zuse s Plankalkül Minimal Hardware Programming: Pseudocodes The IBM 704 and Fortran Functional Programming: LISP The First Step Toward

More information

Introduction to Programming

Introduction to Programming Introduction to Programming session 3 Instructor: Reza Entezari-Maleki Email: entezari@ce.sharif.edu 1 Fall 2010 These slides are created using Deitel s slides Sahrif University of Technology Outlines

More information

Evolution of the Major Programming Languages

Evolution of the Major Programming Languages Evolution of the Major Programming Languages SANGJI University Kwangman Ko (kkman@sangji.ac.kr) Genealogy of Common Languages kkman@sangji.ac.kr 2 1-3 Minimal Hardware Programming: Pseudocodes What was

More information

Programming Languages 1. Introduction. Oscar Nierstrasz

Programming Languages 1. Introduction. Oscar Nierstrasz Programming Languages 1. Introduction Oscar Nierstrasz Roadmap > Course Schedule > Programming Paradigms > A Quick Tour of Programming Language History Programming Languages Lecturer: Assistants: WWW:

More information

Evolution of PL s. EECS 476, Prog. Lang. Design/ page 1

Evolution of PL s. EECS 476, Prog. Lang. Design/ page 1 Evolution of PL s I. Ways of Organizing the evolution of PL s A. Types of PL s [Sebesta p. 37] 1. Procedural (Imperative) [F&G, p. 39] 2. Functional (applicative) [F&G, p. 41] 3. Logical (declarative)

More information

CS 430 Spring History of Programming Languages. Mike Lam, Professor. John McCarthy ( ) Inventor of LISP

CS 430 Spring History of Programming Languages. Mike Lam, Professor. John McCarthy ( ) Inventor of LISP CS 430 Spring 2015 Mike Lam, Professor Dennis Ritchie (1941-2011) Inventor of C John McCarthy (1927-2011) Inventor of LISP History of Programming Languages All images taken from Wikipedia unless stated

More information

8/23/18. Programming Language Genealogy The Evolution of Programming Languages. Zuse s Plankalkül. Plankalkül Syntax. Machine Code

8/23/18. Programming Language Genealogy The Evolution of Programming Languages. Zuse s Plankalkül. Plankalkül Syntax. Machine Code Programming Language Genealogy The Evolution of Programming Languages In Text: Chapter 2 2 Zuse s Plankalkül Designed in 1945, but not published until 1972 Never implemented Advanced data structures floating

More information

Programming Languages (CSCI 4430/6430) History, Syntax, Semantics, Essentials, Paradigms

Programming Languages (CSCI 4430/6430) History, Syntax, Semantics, Essentials, Paradigms Programming Languages (CSCI 4430/6430) History, Syntax, Semantics, Essentials, Paradigms Carlos Varela Rennselaer Polytechnic Institute August 30, 2016 C. Varela 1 The first programmer ever Ada Augusta,

More information

General Concepts. Abstraction Computational Paradigms Implementation Application Domains Influence on Success Influences on Design

General Concepts. Abstraction Computational Paradigms Implementation Application Domains Influence on Success Influences on Design General Concepts Abstraction Computational Paradigms Implementation Application Domains Influence on Success Influences on Design 1 Abstractions in Programming Languages Abstractions hide details that

More information

Programming Languages 2nd edition Tucker and Noonan"

Programming Languages 2nd edition Tucker and Noonan Programming Languages 2nd edition Tucker and Noonan" " Chapter 1" Overview" " A good programming language is a conceptual universe for thinking about programming. " " " " " " " " " " " " "A. Perlis" "

More information

Programming Language Concepts 1982, 1987, Outline. Period

Programming Language Concepts 1982, 1987, Outline. Period Programming Language Concepts 1982, 1987, 1997 Mehdi Jazayeri Distributed Systems Group Technische Universität Wien mjazayeri@alum.mit.edu http://www.infosys.tuwien.ac.at Outline Computer science environment

More information

What is a programming language?

What is a programming language? Overview Introduction Motivation Why study programming languages? Some key concepts What is a programming language? What is a programming language?...there is no agreement on what a programming language

More information

Chapter 2 Preview. Preview. History of Programming Languages. History of Programming Languages. History of Programming Languages

Chapter 2 Preview. Preview. History of Programming Languages. History of Programming Languages. History of Programming Languages Chapter 2 Preview Evolution of the Major Programming Languages The Beginnings of Data Abstraction: SIMULA 67 Orthogonal Design: ALGOL 68 Some Early Descendants of the ALGOLs Programming Based on Logic:

More information

Topic I. Introduction and motivation References: Chapter 1 of Concepts in programming languages by J. C. Mitchell. CUP, 2003.

Topic I. Introduction and motivation References: Chapter 1 of Concepts in programming languages by J. C. Mitchell. CUP, 2003. Topic I Introduction and motivation References: Chapter 1 of Concepts in programming languages by J. C. Mitchell. CUP, 2003. Chapter 1 of Programming languages: Design and implementation (3RD EDITION)

More information

Computer Fundamentals: Pradeep K. Sinha & Priti Sinha

Computer Fundamentals: Pradeep K. Sinha & Priti Sinha Computer Fundamentals Pradeep K. Sinha Priti Sinha Chapter 12 Computer Languages Slide 1/64 Learning Objectives In this chapter you will learn about: Computer languages or programming languages Three broad

More information

Programming Languages A few bits of history

Programming Languages A few bits of history Programming Languages A few bits of history A (biased, incomplete, selective) collection of impressions Hal Perkins Spring 2011 Programming Languages - Spring 2011 1 Some Sources & References History of

More information

Chapter 1. Preliminaries

Chapter 1. Preliminaries Chapter 1 Preliminaries Chapter 1 Topics Reasons for Studying Concepts of Programming Languages Programming Domains Language Evaluation Criteria Influences on Language Design Language Categories Language

More information

PROGRAMMING LANGUAGE PARADIGMS & THE MAIN PRINCIPLES OF OBJECT-ORIENTED PROGRAMMING

PROGRAMMING LANGUAGE PARADIGMS & THE MAIN PRINCIPLES OF OBJECT-ORIENTED PROGRAMMING 10.2478/cris-2013-0011 PROGRAMMING LANGUAGE PARADIGMS & THE MAIN PRINCIPLES OF OBJECT-ORIENTED PROGRAMMING NIKOLETTA MINAROVA 77 INTRODUCTION Since the first design concept of computers came into the world,

More information

8/27/17. CS-3304 Introduction. What will you learn? Semester Outline. Websites INTRODUCTION TO PROGRAMMING LANGUAGES

8/27/17. CS-3304 Introduction. What will you learn? Semester Outline. Websites INTRODUCTION TO PROGRAMMING LANGUAGES CS-3304 Introduction In Text: Chapter 1 & 2 COURSE DESCRIPTION 2 What will you learn? Survey of programming paradigms, including representative languages Language definition and description methods Overview

More information

PROGRAMMING LANGUAGE PARADIGMS & THE MAIN PRINCIPLES OF OBJECT-ORIENTED PROGRAMMING

PROGRAMMING LANGUAGE PARADIGMS & THE MAIN PRINCIPLES OF OBJECT-ORIENTED PROGRAMMING PROGRAMMING LANGUAGE PARADIGMS & THE MAIN PRINCIPLES OF OBJECT-ORIENTED PROGRAMMING JAN BARTONÍČEK This paper's goal is to briefly explain the basic theory behind programming languages and their history

More information

1. true / false By a compiler we mean a program that translates to code that will run natively on some machine.

1. true / false By a compiler we mean a program that translates to code that will run natively on some machine. 1. true / false By a compiler we mean a program that translates to code that will run natively on some machine. 2. true / false ML can be compiled. 3. true / false FORTRAN can reasonably be considered

More information

1/14/2014. Introduction to CSE 1325 Object Oriented Programming (Using Java) Introduction (Cont.) Introduction

1/14/2014. Introduction to CSE 1325 Object Oriented Programming (Using Java) Introduction (Cont.) Introduction Introduction (Cont.) Introduction to CSE 1325 Object Oriented Programming (Using Java) Sharma Chakravarthy Information Technology Laboratory (IT Lab) Computer Science and Engineering Department The University

More information

Chapter 1. Preliminaries

Chapter 1. Preliminaries Chapter 1 Preliminaries Chapter 1 Topics Reasons for Studying Concepts of Programming Languages Programming Domains Language Evaluation Criteria Influences on Language Design Language Categories Language

More information

Informal Semantics of Data. semantic specification names (identifiers) attributes binding declarations scope rules visibility

Informal Semantics of Data. semantic specification names (identifiers) attributes binding declarations scope rules visibility Informal Semantics of Data semantic specification names (identifiers) attributes binding declarations scope rules visibility 1 Ways to Specify Semantics Standards Documents (Language Definition) Language

More information

Organization of Programming Languages (CSE452) Why are there so many programming languages? What makes a language successful?

Organization of Programming Languages (CSE452) Why are there so many programming languages? What makes a language successful? Organization of Programming Languages (CSE452) Instructor: Dr. B. Cheng Fall 2004 1 Why are there so many programming languages? Evolution -- we've learned better ways of doing things over time Socio-economic

More information

Introduction to Computers, the Internet and the Web Pearson Education, Inc. All rights reserved.

Introduction to Computers, the Internet and the Web Pearson Education, Inc. All rights reserved. 1 1 Introduction to Computers, the Internet and the Web 2 The chief merit of language is clearness. Galen Our life is frittered away by detail. Simplify, simplify. Henry David Thoreau He had a wonderful

More information

Principles of Programming Languages. Lecture Outline

Principles of Programming Languages. Lecture Outline Principles of Programming Languages CS 492 Lecture 1 Based on Notes by William Albritton 1 Lecture Outline Reasons for studying concepts of programming languages Programming domains Language evaluation

More information

Concepts in Programming Languages

Concepts in Programming Languages Concepts in Programming Languages Marcelo Fiore Computer Laboratory University of Cambridge 2012 2013 (Easter Term) 1 Practicalities Course web page: with lecture

More information

SOFTWARE ARCHITECTURE 6. LISP

SOFTWARE ARCHITECTURE 6. LISP 1 SOFTWARE ARCHITECTURE 6. LISP Tatsuya Hagino hagino@sfc.keio.ac.jp slides URL https://vu5.sfc.keio.ac.jp/sa/ 2 Compiler vs Interpreter Compiler Translate programs into machine languages Compilers are

More information

Concepts of Programming Languages

Concepts of Programming Languages Concepts of Programming Languages Lecture 1 - Introduction Patrick Donnelly Montana State University Spring 2014 Patrick Donnelly (Montana State University) Concepts of Programming Languages Spring 2014

More information

Fundamentals of Programming Languages. PL families Lecture 02 sl. dr. ing. Ciprian-Bogdan Chirila

Fundamentals of Programming Languages. PL families Lecture 02 sl. dr. ing. Ciprian-Bogdan Chirila Fundamentals of Programming Languages PL families Lecture 02 sl. dr. ing. Ciprian-Bogdan Chirila Lecture outline Imperative PLs Functional PLs Declarative PLs The three PL families There are several criteria

More information

Why study Programming Language Concepts? Chapter One. Language Evaluation Criteria. Programming Domains. Readability Writability Reliability Cost

Why study Programming Language Concepts? Chapter One. Language Evaluation Criteria. Programming Domains. Readability Writability Reliability Cost Chapter One Preliminaries, including Why study PL concepts? Programming domains PL evaluation criteria What influences PL design? Tradeoffs faced by programming languages Implementation methods Programming

More information

Chapter 1 Preliminaries

Chapter 1 Preliminaries Chapter 1 Preliminaries Chapter 1 Topics Reasons for Studying Concepts of Programming Languages Programming Domains Language Evaluation Criteria Influences on Language Design Language Categories Language

More information

Continuations provide a novel way to suspend and reexecute

Continuations provide a novel way to suspend and reexecute Continuations provide a novel way to suspend and reexecute computations. 2. ML ( Meta Language ) Strong, compile-time type checking. Types are determined by inference rather than declaration. Naturally

More information

Final-Term Papers Solved MCQS with Reference

Final-Term Papers Solved MCQS with Reference Solved MCQ(S) From FinalTerm Papers BY Arslan Jan 14, 2018 V-U For Updated Files Visit Our Site : Www.VirtualUstaad.blogspot.com Updated. Final-Term Papers Solved MCQS with Reference 1. The syntax of PHP

More information

Com S 541. Programming Languages I

Com S 541. Programming Languages I Programming Languages I Lecturer: TA: Markus Lumpe Department of Computer Science 113 Atanasoff Hall http://www.cs.iastate.edu/~lumpe/coms541.html TR 12:40-2, W 5 Pramod Bhanu Rama Rao Office hours: TR

More information

Chapter 1: Introduction

Chapter 1: Introduction Chapter 1: Introduction Outline Introduction What Is a Computer? Computer Hardware Computer Software Computer Programming Languages Machine Code, Assembly Languages and High-Level Languages. The History

More information

Functional Programming. Big Picture. Design of Programming Languages

Functional Programming. Big Picture. Design of Programming Languages Functional Programming Big Picture What we ve learned so far: Imperative Programming Languages Variables, binding, scoping, reference environment, etc What s next: Functional Programming Languages Semantics

More information

COSC 2P90 Programming Languages & Object-Orientation

COSC 2P90 Programming Languages & Object-Orientation COSC 2P90 Programming Languages & Object-Orientation Hi! 1 Textbooks Main Text Comparative Programming Languages 3rd ed.; Wilson, LB & Clark, RG; Addison-Wesley (2001); ISBN 0-201-71012-9 Supplemental

More information

PLAGIARISM. Administrivia. Course home page: Introduction to Programming Languages and Compilers

PLAGIARISM. Administrivia. Course home page: Introduction to Programming Languages and Compilers Administrivia Introduction to Programming Languages and Compilers CS164 11:00-12:00 MWF 306 Soda Notes by G. Necula, with additions by P. Hilfinger Course home page: http://www-inst.eecs.berkeley.edu/~cs164

More information

Introduction to Programming Languages and Compilers. CS164 11:00-12:00 MWF 306 Soda

Introduction to Programming Languages and Compilers. CS164 11:00-12:00 MWF 306 Soda Introduction to Programming Languages and Compilers CS164 11:00-12:00 MWF 306 Soda Notes by G. Necula, with additions by P. Hilfinger Prof. Hilfinger CS 164 Lecture 1 1 Administrivia Course home page:

More information

CSCI170 Lecture 1: Analysis of Programming Languages. John Magee 1 September 2011 Some material copyright Jones and Bartlett

CSCI170 Lecture 1: Analysis of Programming Languages. John Magee 1 September 2011 Some material copyright Jones and Bartlett CSCI170 Lecture 1: Analysis of Programming Languages John Magee 1 September 2011 Some material copyright Jones and Bartlett 1 Overview/Questions How can we control the computer s circuits? How does the

More information

Introduction to Computer Science I

Introduction to Computer Science I Introduction to Computer Science I CSE 1020 www.cse.yorku.ca/course/1020 Programming Contests in September and October Everyone is welcome to participate in these contests. The students who will represent

More information

1 A question of semantics

1 A question of semantics PART I BACKGROUND 1 A question of semantics The goal of this chapter is to give the reader a glimpse of the applications and problem areas that have motivated and to this day continue to inspire research

More information

Chapter 5 Names, Binding, Type Checking and Scopes

Chapter 5 Names, Binding, Type Checking and Scopes Chapter 5 Names, Binding, Type Checking and Scopes Names - We discuss all user-defined names here - Design issues for names: -Maximum length? - Are connector characters allowed? - Are names case sensitive?

More information

CSc 372. Comparative Programming Languages. 2 : Functional Programming. Department of Computer Science University of Arizona

CSc 372. Comparative Programming Languages. 2 : Functional Programming. Department of Computer Science University of Arizona 1/37 CSc 372 Comparative Programming Languages 2 : Functional Programming Department of Computer Science University of Arizona collberg@gmail.com Copyright c 2013 Christian Collberg 2/37 Programming Paradigms

More information

Logic Programming II & Revision

Logic Programming II & Revision Logic Programming II & Revision Gerardo Schneider Department of Informatics University of Oslo 1 Some corrections (1) hsiblings(x,y) :- child(x,parent), child(y,parent), X \== Y, child(x,parent1), child(y,parent2),

More information

Imperative Programming

Imperative Programming Naming, scoping, binding, etc. Instructor: Dr. B. Cheng Fall 2004 1 Imperative Programming The central feature of imperative languages are variables Variables are abstractions for memory cells in a Von

More information

CS101 Introduction to Programming Languages and Compilers

CS101 Introduction to Programming Languages and Compilers CS101 Introduction to Programming Languages and Compilers In this handout we ll examine different types of programming languages and take a brief look at compilers. We ll only hit the major highlights

More information

CS 415 Midterm Exam Spring 2002

CS 415 Midterm Exam Spring 2002 CS 415 Midterm Exam Spring 2002 Name KEY Email Address Student ID # Pledge: This exam is closed note, closed book. Good Luck! Score Fortran Algol 60 Compilation Names, Bindings, Scope Functional Programming

More information

Languages october 22, 2017 Éric Lévénez <http://www.levenez.com/lang/> FORTRAN III end-1958 FORTRAN II FORTRAN I october 1956

Languages october 22, 2017 Éric Lévénez <http://www.levenez.com/lang/> FORTRAN III end-1958 FORTRAN II FORTRAN I october 1956 1954 1957 FORTRAN november 1954 FORTRAN I october 1956 FORTRAN II 1957 FORTRAN III end-1958 B-O 1957 Flow-Matic 1958 COBOL 1959 JOVIAL 1959 IAL 1958 ALGOL 58 1958 Lisp 1958 Lisp 1 1959 Languages october

More information

Page # CSCI: 4500/6500 Programming Languages. Programming Paradigm: Imperative. Programming Paradigm: Declarative. First General Purpose Machine

Page # CSCI: 4500/6500 Programming Languages. Programming Paradigm: Imperative. Programming Paradigm: Declarative. First General Purpose Machine CSCI: 4500/6500 Programming Languages Origin Maria Hybinette, UGA 1 Programming Paradigm: Imperative Programming Paradigm: Declarative Imperative programming: Describes computation in terms of a program

More information

CSC 326H1F, Fall Programming Languages. What languages do you know? Instructor: Ali Juma. A survey of counted loops: FORTRAN

CSC 326H1F, Fall Programming Languages. What languages do you know? Instructor: Ali Juma. A survey of counted loops: FORTRAN What languages do you know? CSC 326H1F, Programming Languages The usual suspects: C, C++, Java fine languages nearly the same Perhaps you've also learned some others? assembler Basic, Visual Basic, Turing,

More information

Low-Level Languages. Computer Programs and Programming Languages

Low-Level Languages. Computer Programs and Programming Languages Computer Programs and Programming Languages What is a computer program? Set of instructions that directs computer to perform tasks Programming used to write instructions 1 Computer Programs and Programming

More information

The results for a few specific cases below are indicated. allequal ([1,1,1,1]) should return true allequal ([1,1,2,1]) should return false

The results for a few specific cases below are indicated. allequal ([1,1,1,1]) should return true allequal ([1,1,2,1]) should return false Test 1 Multiple Choice. Write your answer to the LEFT of each problem. 4 points each 1. Which celebrity has not received an ACM Turing Award? A. Alan Kay B. John McCarthy C. Dennis Ritchie D. Bjarne Stroustrup

More information

Programmiersprachen (Programming Languages)

Programmiersprachen (Programming Languages) 2016-05-13 Preface Programmiersprachen (Programming Languages) coordinates: lecturer: web: usable for: requirements: No. 185.208, VU, 3 ECTS Franz Puntigam http://www.complang.tuwien.ac.at/franz/ps.html

More information

CS383 PROGRAMMING LANGUAGES. Kenny Q. Zhu Dept. of Computer Science Shanghai Jiao Tong University

CS383 PROGRAMMING LANGUAGES. Kenny Q. Zhu Dept. of Computer Science Shanghai Jiao Tong University CS383 PROGRAMMING LANGUAGES Kenny Q. Zhu Dept. of Computer Science Shanghai Jiao Tong University KENNY Q. ZHU Research Interests: Programming Languages Probabilistic Programming Data Processing Concurrency

More information

Introduction. chapter Functions

Introduction. chapter Functions chapter 1 Introduction In this chapter we set the stage for the rest of the book. We start by reviewing the notion of a function, then introduce the concept of functional programming, summarise the main

More information

Question No: 1 ( Marks: 1 ) - Please choose one One difference LISP and PROLOG is. AI Puzzle Game All f the given

Question No: 1 ( Marks: 1 ) - Please choose one One difference LISP and PROLOG is. AI Puzzle Game All f the given MUHAMMAD FAISAL MIT 4 th Semester Al-Barq Campus (VGJW01) Gujranwala faisalgrw123@gmail.com MEGA File Solved MCQ s For Final TERM EXAMS CS508- Modern Programming Languages Question No: 1 ( Marks: 1 ) -

More information

Lecture 1: Course Introduction

Lecture 1: Course Introduction Lecture 1: Course Introduction CS164: Programming Languages and Compilers P. N. Hilfinger, 787 Soda Spring 2015 Acknowledgement. Portions taken from CS164 notes by G. Necula. Last modified: Wed Jan 21

More information

Topic IV. Block-structured procedural languages Algol and Pascal. References:

Topic IV. Block-structured procedural languages Algol and Pascal. References: References: Topic IV Block-structured procedural languages Algol and Pascal Chapters 5 and 7, of Concepts in programming languages by J. C. Mitchell. CUP, 2003. Chapters 10( 2) and 11( 1) of Programming

More information

Chapter 11 :: Functional Languages

Chapter 11 :: Functional Languages Chapter 11 :: Functional Languages Programming Language Pragmatics Michael L. Scott Copyright 2016 Elsevier 1 Chapter11_Functional_Languages_4e - Tue November 21, 2017 Historical Origins The imperative

More information

Chapter 1. Preview. Reason for Studying OPL. Language Evaluation Criteria. Programming Domains

Chapter 1. Preview. Reason for Studying OPL. Language Evaluation Criteria. Programming Domains Chapter 1. Preview Reason for Studying OPL Reason for Studying OPL? Programming Domains Language Evaluation Criteria Language Categories Language Design Trade-Offs Implementation Methods Programming Environments

More information

CISC 860 September 14, Milestones in the History of PLs

CISC 860 September 14, Milestones in the History of PLs CISC 860 September 14, 2009 Milestones in the History of PLs P. Wegner, 1976 3 Phases of Language Development 1950-60 Discovery & Description Basic concepts discovered PLs regarded as tools only 1961-69

More information

Lecture 1: Preliminaries

Lecture 1: Preliminaries Lecture 1: Preliminaries Edgardo Molina Department of Computer Science City College of New York August 30, 2011 Edgardo Molina (CS@CCNY) Lecture 1 August 30, 2011 1 / 44 Info and Schedule Course Info and

More information

INSTITUTE OF AERONAUTICAL ENGINEERING

INSTITUTE OF AERONAUTICAL ENGINEERING INSTITUTE OF AERONAUTICAL ENGINEERING (Autonomous) Dundigal, Hyderabad -500 043 INFORMATION TECHNOLOGY TUTORIAL QUESTION BANK Name : PRINCIPLES OF PROGRAMMING LANGUAGES Code : A40511 Class : II B. Tech

More information

Informatica 3 Syntax and Semantics

Informatica 3 Syntax and Semantics Informatica 3 Syntax and Semantics Marcello Restelli 9/15/07 Laurea in Ingegneria Informatica Politecnico di Milano Introduction Introduction to the concepts of syntax and semantics Binding Variables Routines

More information

Component V Supporting Materials / Learn More Interesting Facts. Interesting Facts

Component V Supporting Materials / Learn More Interesting Facts. Interesting Facts Component V Supporting Materials / Learn More 1.4.1 Interesting Facts No. Interesting Facts 1. All computers operate by following machine language programs. 2. Machine language programs are long sequence

More information

Chapter 3:: Names, Scopes, and Bindings (cont.)

Chapter 3:: Names, Scopes, and Bindings (cont.) Chapter 3:: Names, Scopes, and Bindings (cont.) Programming Language Pragmatics Michael L. Scott Review What is a regular expression? What is a context-free grammar? What is BNF? What is a derivation?

More information

CSC 533: Programming Languages. Spring 2015

CSC 533: Programming Languages. Spring 2015 S 533: Programming Languages Spring 2015 Background machine à assembly à high-level languages software development methodologies key languages Syntax grammars, BNF derivation trees, parsing EBNF, syntax

More information

Lecture 1: Course Introduction

Lecture 1: Course Introduction Lecture 1: Course Introduction CS164: Programming Languages and Compilers P. N. Hilfinger, 787 Soda Fall 2013 Acknowledgement. Portions taken from CS164 notes by G. Necula. Last modified: Thu Aug 29 16:03:34

More information

Objective: To learn meaning and concepts of programming. Outcome: By the end of this students should be able to describe the meaning of programming

Objective: To learn meaning and concepts of programming. Outcome: By the end of this students should be able to describe the meaning of programming 30 th September 2018 Objective: To learn meaning and concepts of programming Outcome: By the end of this students should be able to describe the meaning of programming Section 1: What is a programming

More information

CS 113: Introduction to

CS 113: Introduction to CS 113: Introduction to Course information MWF 12:20-1:10pm 1/21-2/15, 306 Hollister Hall Add/drop deadline: 1/28 C Instructor: David Crandall See website for office hours and contact information Prerequisites

More information

Design & Implementation Overview

Design & Implementation Overview P Fall 2017 Outline P 1 2 3 4 5 6 7 P P Ontological commitments P Imperative l Architecture: Memory cells variables Data movement (memory memory, CPU memory) assignment Sequential machine instruction execution

More information

Programming Paradigms

Programming Paradigms Programming Paradigms Programming languages A Programming language is a notational system for describing tasks/computations in a machine and human readable form. Most computer languages are designed to

More information

St. MARTIN S ENGINEERING COLLEGE Dhulapally, Secunderabad

St. MARTIN S ENGINEERING COLLEGE Dhulapally, Secunderabad St. MARTIN S ENGINEERING COLLEGE Dhulapally, Secunderabad-00 014 Subject: PPL Class : CSE III 1 P a g e DEPARTMENT COMPUTER SCIENCE AND ENGINEERING S No QUESTION Blooms Course taxonomy level Outcomes UNIT-I

More information

Learning the Hard Way

Learning the Hard Way Learning the Hard Way A History 1843-1980 of Software Engineering Fred Brooks University of North Carolina at Chapel Hill brooks@cs.unc.edu FPB 5/30/18 Disclaimer I ve tried to get dates right, but I do

More information

COP4020 Programming Languages. Compilers and Interpreters Robert van Engelen & Chris Lacher

COP4020 Programming Languages. Compilers and Interpreters Robert van Engelen & Chris Lacher COP4020 ming Languages Compilers and Interpreters Robert van Engelen & Chris Lacher Overview Common compiler and interpreter configurations Virtual machines Integrated development environments Compiler

More information

Compiling and Interpreting Programming. Overview of Compilers and Interpreters

Compiling and Interpreting Programming. Overview of Compilers and Interpreters Copyright R.A. van Engelen, FSU Department of Computer Science, 2000 Overview of Compilers and Interpreters Common compiler and interpreter configurations Virtual machines Integrated programming environments

More information

CSC 533: Organization of Programming Languages. Spring 2005

CSC 533: Organization of Programming Languages. Spring 2005 S 533: Organization of Programming Languages Spring 2005 Background machine assembly high-level languages software development methodologies key languages Syntax grammars, BNF derivation trees, parsing

More information

Chapter 3:: Names, Scopes, and Bindings (cont.)

Chapter 3:: Names, Scopes, and Bindings (cont.) Chapter 3:: Names, Scopes, and Bindings (cont.) Programming Language Pragmatics Michael L. Scott Review What is a regular expression? What is a context-free grammar? What is BNF? What is a derivation?

More information

Cunning Plan. Gone In Sixty Seconds. History of Programming Languages. Functional Programming. Functional Programming. Review and Administrivia

Cunning Plan. Gone In Sixty Seconds. History of Programming Languages. Functional Programming. Functional Programming. Review and Administrivia History of Programming Languages Functional Programming #1 Cunning Plan Review and Administrivia Office Hours History Lesson Babbage to C# Functional Programming OCaml Types Pattern Matching Higher-Order

More information