Presentation is loading. Please wait.

Presentation is loading. Please wait.

Programming Languages Language Design Issues Why study programming languages Language development Software architectures Design goals Attributes of a good.

Similar presentations


Presentation on theme: "Programming Languages Language Design Issues Why study programming languages Language development Software architectures Design goals Attributes of a good."— Presentation transcript:

1 Programming Languages Language Design Issues Why study programming languages Language development Software architectures Design goals Attributes of a good programming language Language paradigms Standardization and internationalization

2 Why study programming languages To improve your ability to develop effective algorithms To improve your use of existing programming languages To increase your vocabulary of useful programming constructs

3 Why study programming languages To allow a better choice of programming language To make it easier to learn a new language To make it easier to design a new language

4 Language development Numerically based languages Computing mathematical expressions FORTRAN, Algol, Pascal, PL/1, BASIC, C, C++ Business languages COBOL (Common Business Oriented Language) English-like notation

5 Language development Artificial intelligence languages Tree search; Rule-based paradigm LISP (LISt Processing) PROLOG (PROgramming in LOGic) System languages C, C++ Script languages: AWK, Perl, TCL/TK Web programming: HTML, XML, Java, Microsoft *.NET family

6 Software architectures Mainframe era Batch processing (batches of files) Interactive processing (time sharing) Effects on language design File I/O in batch processing Error handling in batch processing Time constraints in interactive processing

7 Software architectures Personal computers Interactive processing Embedded system environments Effects on language design No need for time sharing Good interactive graphics Non-standard I/O devices for embedded systems

8 Software architectures Networking era Client-server model of computing Server: a program that provides information Client - a program that requests information Effects on language design Interaction between the client and server programs Active web pages, Security issues, Performance

9 Design Goals During 1950s--1960s - Run-time considerations Programmers are cheap, machines expensive; Keep the machine busy Today - program development time considerations CPU power and memory are very cheap

10 Attributes of a good language Conceptual integrity Orthogonality Naturalness for the application Support for abstraction Ease of program verification Programming environment Portability of programs Cost of use

11 Language paradigms Imperative / procedural languages Applicative / functional languages Rule-based / declarative languages Object-oriented languages

12 Imperative / procedural languages Statement oriented languages that change machine state (C, Pascal, FORTRAN, COBOL) Computation: a sequence of machine states (contents of memory) Syntax: S1, S2, S3,... where S1, S2, … are statements

13 Applicative / functional languages Programming consists of building the function that computes the answer Computation: Function composition is major operation (ML, LISP) Syntax: P1(P2(P3(X)))

14 Rule-based / declarative languages Computation: Actions are specified by rules that check for the presence of certain enabling conditions. (Prolog) The order of execution is determined by the enabling conditions, not by the order of the statements. Syntax: Condition  Action

15 Object-oriented languages Imperative languages that merge applicative design with imperative statements (Java, C++, Smalltalk) Syntax: Set of objects (classes) containing data (imperative concepts) and methods (applicative concepts)

16 Language standardization The need for standards - to increase portability of programs Problem: When to standardize a language? If too late - many incompatible versions If too early - no experience with language Problem: What happens with the software developed before the standardization? Ideally, new standards have to be compatible with older standards.

17 Internationalization I18N issue - How to specify languages useful in a global economy? What character codes to use? Collating sequences? - How do you alphabetize various languages? Dates? - What date is 10/12/01? 10-12-01? 12.10.01 ? Is it a date in October or December?

18 Internationalization Time? - How do you handle time zones, summer time in Europe, daylight savings time in US, Southern hemisphere is 6 months out of phase with northern hemisphere, the date to change from summer to standard time is not consistent. Currency? - How to handle dollars, pounds, marks, francs, euros, etc.

19 Programming environments Programming environment: the environment in which programs are created and tested. Separate compilation Separate execution Testing Debugging

20 Programming environments Effects on language design: Modular organization Local/global variables Libraries

21 Programming environments Process control languages Scripting languages Usually interpreted, Able to process programs and data files Specify a sequence of operations on program and data files. Awk, Perl, Tcl/Tk

22 Summary Language design must: Allow program solution to match problem structure Allow for world-wide use Be easy to prove correctness of solutions


Download ppt "Programming Languages Language Design Issues Why study programming languages Language development Software architectures Design goals Attributes of a good."

Similar presentations


Ads by Google